Skip to content

Commit 259e45c

Browse files
committed
refactor: [PR4] drop the feature-manager refresh removed in PR3
The KMP-backed OSFeatureManager this branch now sits on has no refreshIfEmpty. Flags are re-read through the OSFeatureFlagsStore subscription when a fetch lands, so the prewarm re-read this called for has no counterpart and the line goes away. OSFeatureManager.shared stays. OneSignal.m already builds it from StartFeatureFlagsRefresh during init, so reading it here does not change which flags the process starts with.
1 parent 6546daf commit 259e45c

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

‎iOS_SDK/OneSignalSDK/OneSignalUser/Source/OneSignalUserManagerImpl.swift‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ public class OneSignalUserManagerImpl: NSObject, OneSignalUserManager {
128128

129129
let newRecordsState = OSNewRecordsState()
130130

131-
// Shared instances: remote params hydrate them before this class is started, and a
132-
// fresh instance here would read none of it.
131+
// Hydrated before this class is started, jwtConfig by remote params and featureManager by
132+
// OSFeatureFlagsRefreshService, so a fresh instance here would read none of it.
133133
let featureManager = OSFeatureManager.shared
134134
let jwtConfig = OSUserJwtConfig.shared
135135
let identityVerificationService: OSIdentityVerificationService
@@ -255,7 +255,6 @@ public class OneSignalUserManagerImpl: NSObject, OneSignalUserManager {
255255
pushSubscriptionModelStore.refresh()
256256
// Same prewarm gap as the stores: init may have read UserDefaults while it was locked.
257257
jwtConfig.refreshIfUnknown()
258-
featureManager.refreshIfEmpty()
259258

260259
OSNotificationsManager.delegate = self
261260

0 commit comments

Comments
 (0)