diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 306bf957d..11e7e55d7 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -13,7 +13,7 @@ dokka = "2.0.0" kotlinx_datetime = "0.6.2" kotlinx_coroutines = "1.10.2" pubnub_js = "10.1.0" -pubnub_swift = "9.3.5" +pubnub_swift = "10.1.0" [libraries] retrofit2 = { module = "com.squareup.retrofit2:retrofit", version.ref = "retrofit2" } diff --git a/pubnub-kotlin/pubnub-kotlin-api/src/appleMain/kotlin/com/pubnub/api/endpoints/presence/HereNow.ios.kt b/pubnub-kotlin/pubnub-kotlin-api/src/appleMain/kotlin/com/pubnub/api/endpoints/presence/HereNow.ios.kt index 87ccd1334..5b998784f 100644 --- a/pubnub-kotlin/pubnub-kotlin-api/src/appleMain/kotlin/com/pubnub/api/endpoints/presence/HereNow.ios.kt +++ b/pubnub-kotlin/pubnub-kotlin-api/src/appleMain/kotlin/com/pubnub/api/endpoints/presence/HereNow.ios.kt @@ -15,6 +15,7 @@ import com.pubnub.kmp.onFailureHandler import com.pubnub.kmp.onSuccessHandler import com.pubnub.kmp.safeCast import kotlinx.cinterop.ExperimentalForeignApi +import platform.Foundation.NSNumber /** * @see [PubNub.hereNow] @@ -37,9 +38,8 @@ class HereNowImpl( channelGroups = channelGroups, includeState = includeState, includeUUIDs = includeUUIDs, - // todo pass limit and offset once available - // limit = limit, - // offset = offset, + limit = limit.toLong(), + offset = offset?.let { NSNumber(it) }, onSuccess = callback.onSuccessHandler { PNHereNowResult( totalChannels = it?.totalChannels()?.toInt() ?: 0, diff --git a/pubnub-kotlin/pubnub-kotlin-api/src/jsMain/kotlin/Pubnub.d.kt b/pubnub-kotlin/pubnub-kotlin-api/src/jsMain/kotlin/Pubnub.d.kt index 0d1bec22b..7b338bf06 100644 --- a/pubnub-kotlin/pubnub-kotlin-api/src/jsMain/kotlin/Pubnub.d.kt +++ b/pubnub-kotlin/pubnub-kotlin-api/src/jsMain/kotlin/Pubnub.d.kt @@ -763,6 +763,10 @@ open external class PubNub(config: Any /* UUID | UserId */) { var includeUUIDs: Boolean? var includeState: Boolean? + + var limit: Number? + + var offset: Number? } interface HereNowOccupantData {