spotny-sdk 1.0.25 → 1.0.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -270,8 +270,12 @@ public class SpotnyBeaconScanner: NSObject {
|
|
|
270
270
|
return
|
|
271
271
|
}
|
|
272
272
|
|
|
273
|
+
// Clear any JWT restored from Keychain (survives uninstall) so the verify call goes out
|
|
274
|
+
// unauthenticated and concurrent beacon events are blocked until the new JWT arrives.
|
|
275
|
+
sdkToken = nil
|
|
276
|
+
sdkTokenExpiry = nil
|
|
277
|
+
|
|
273
278
|
// Send token + apiKey + identifierId to backend — response returns a JWT used for all subsequent calls
|
|
274
|
-
// sdkToken is nil here so no Authorization header is injected on this call
|
|
275
279
|
let verifyPayload: [String: Any] = ["api_token": token, "api_key": key, "identifier_id": uid, "device_id": getDeviceId()]
|
|
276
280
|
post(endpoint: "\(apiBasePath)/verify", payload: verifyPayload) { [weak self] result in
|
|
277
281
|
guard let self = self else { return }
|