Skip to content

Commit

Permalink
Fix compilation issues with Integration.kt
Browse files Browse the repository at this point in the history
  • Loading branch information
DRSchlaubi committed Mar 25, 2023
1 parent 0dc99fc commit efb948c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions core/src/commonMain/kotlin/entity/Integration.kt
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,17 @@ import dev.kord.core.behavior.RoleBehavior
import dev.kord.core.behavior.UserBehavior
import dev.kord.core.cache.data.IntegrationData
import dev.kord.core.exception.EntityNotFoundException
import dev.kord.core.hash
import dev.kord.core.supplier.EntitySupplier
import dev.kord.core.supplier.EntitySupplyStrategy
import dev.kord.rest.builder.integration.IntegrationModifyBuilder
import dev.kord.rest.request.RestRequestException
import kotlinx.datetime.Instant
import java.util.*
import kotlin.DeprecationLevel.HIDDEN
import kotlin.contracts.InvocationKind
import kotlin.contracts.contract
import kotlin.js.JsName
import kotlin.jvm.JvmName
import kotlin.time.Duration

/**
Expand Down Expand Up @@ -52,6 +54,7 @@ public class Integration(
get() = data.enabled

@Deprecated("Binary compatibility, was non-nullable before. Keep for some releases.", level = HIDDEN)
@JsName("_isSyncing") // binary compatibility with js doesn't matter as this is the first JS release
public fun isSyncing(): Boolean = isSyncing!!

/**
Expand Down Expand Up @@ -171,7 +174,7 @@ public class Integration(
override fun withStrategy(strategy: EntitySupplyStrategy<*>): Integration =
Integration(data, kord, strategy.supply(kord))

override fun hashCode(): Int = Objects.hash(id)
override fun hashCode(): Int = hash(id)

override fun equals(other: Any?): Boolean = when (other) {
is Integration -> other.id == id && other.guildId == guildId
Expand Down

0 comments on commit efb948c

Please sign in to comment.