Hey, we are trying to ask for the UNUserNotificati...
# ios
s
Hey, we are trying to ask for the UNUserNotificationCenter authorization in kotlin and are experiencing the following error. Any idea what the reason could be?
Copy code
@ExperimentalUnsignedTypes
actual fun checkSystemPermissionsThunk(): Thunk<AppState> = { dispatch, _, _ ->
    val center = UNUserNotificationCenter.currentNotificationCenter()
    center.requestAuthorizationWithOptions(
        (UNNotificationPresentationOptionAlert + UNNotificationPresentationOptionSound)
    ) { isSuccess, error -> }
}
Stacktrace:
Copy code
at 0   Multiplatform Redux Sample          0x00000001084d67cf kfun:kotlin.Throwable#<init>(kotlin.String?){} + 95
    at 1   Multiplatform Redux Sample          0x00000001084cee5d kfun:kotlin.Exception#<init>(kotlin.String?){} + 93
    at 2   Multiplatform Redux Sample          0x00000001084cf0cd kfun:kotlin.RuntimeException#<init>(kotlin.String?){} + 93
    at 3   Multiplatform Redux Sample          0x000000010850427d kfun:kotlin.native.IncorrectDereferenceException#<init>(kotlin.String){} + 93
    at 4   Multiplatform Redux Sample          0x000000010850851f ThrowIllegalObjectSharingException + 623
    at 5   Multiplatform Redux Sample          0x00000001085f8852 _ZN12_GLOBAL__N_128throwIllegalSharingExceptionEP9ObjHeader + 34
    at 6   Multiplatform Redux Sample          0x00000001085fcd8d _ZN12_GLOBAL__N_136terminateWithIllegalSharingExceptionEP9ObjHeader + 13
    at 7   Multiplatform Redux Sample          0x000000010862b133 _ZNK16KRefSharedHolder3refIL11ErrorPolicy3EEEP9ObjHeaderv + 67
    at 8   Multiplatform Redux Sample          0x000000010847084a _ZL39Kotlin_Interop_unwrapKotlinObjectHolderP11objc_object + 42
    at 9   Multiplatform Redux Sample          0x0000000108348a6e _63682e64726569706f6c2e6d756c7469706c6174666f726d2e726564757873616d706c652e7368617265643a736861726564_knbridge3 + 222
    at 10  libdispatch.dylib                   0x000000010a0c57ec _dispatch_call_block_and_release + 12
    at 11  libdispatch.dylib                   0x000000010a0c69c8 _dispatch_client_callout + 8
    at 12  libdispatch.dylib                   0x000000010a0cd296 _dispatch_lane_serial_drain + 796
    at 13  libdispatch.dylib                   0x000000010a0cdf9d _dispatch_lane_invoke + 493
    at 14  libdispatch.dylib                   0x000000010a0d9de2 _dispatch_workloop_worker_thread + 882
    at 15  libsystem_pthread.dylib             0x00007fff60c8aa3d _pthread_wqthread + 290
    at 16  libsystem_pthread.dylib             0x00007fff60c89b77 start_wqthread + 15