Skip to content

Commit e993fc0

Browse files
committed
Fix null useIdentityVerification blocking all ops for non-IV apps
When the server omits jwt_required from the params response, safeBool() returned null, leaving useIdentityVerification unset. getNextOps() treated null as "not yet known" and returned null permanently, silently blocking every SDK operation for the session. Default to false when the field is absent so non-IV apps are unaffected by the identity verification gating logic. Made-with: Cursor
1 parent f9d911a commit e993fc0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

OneSignalSDK/onesignal/core/src/main/java/com/onesignal/core/internal/backend/impl/ParamsBackendService.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ internal class ParamsBackendService(
8484
return ParamsObject(
8585
googleProjectNumber = responseJson.safeString("android_sender_id"),
8686
enterprise = responseJson.safeBool("enterp"),
87-
useIdentityVerification = responseJson.safeBool("jwt_required"),
87+
useIdentityVerification = responseJson.safeBool("jwt_required") ?: false,
8888
notificationChannels = responseJson.optJSONArray("chnl_lst"),
8989
firebaseAnalytics = responseJson.safeBool("fba"),
9090
restoreTTLFilter = responseJson.safeBool("restore_ttl_filter"),

0 commit comments

Comments
 (0)