|
47 | 47 | #import <FirebaseCore/FIRLibrary.h> |
48 | 48 | #import <FirebaseInstanceID/FirebaseInstanceID.h> |
49 | 49 | #import <GoogleUtilities/GULReachabilityChecker.h> |
| 50 | +#import <GoogleUtilities/GULUserDefaults.h> |
50 | 51 |
|
51 | 52 | #import "NSError+FIRMessaging.h" |
52 | 53 |
|
@@ -141,7 +142,7 @@ @interface FIRMessaging ()<FIRMessagingClientDelegate, FIRMessagingReceiverDeleg |
141 | 142 | @property(nonatomic, readwrite, strong) FIRMessagingRmqManager *rmq2Manager; |
142 | 143 | @property(nonatomic, readwrite, strong) FIRMessagingReceiver *receiver; |
143 | 144 | @property(nonatomic, readwrite, strong) FIRMessagingSyncMessageManager *syncMessageManager; |
144 | | -@property(nonatomic, readwrite, strong) NSUserDefaults *messagingUserDefaults; |
| 145 | +@property(nonatomic, readwrite, strong) GULUserDefaults *messagingUserDefaults; |
145 | 146 |
|
146 | 147 | /// Message ID's logged for analytics. This prevents us from logging the same message twice |
147 | 148 | /// which can happen if the user inadvertently calls `appDidReceiveMessage` along with us |
@@ -179,7 +180,7 @@ + (FIRMessaging *)messaging { |
179 | 180 |
|
180 | 181 | - (instancetype)initWithAnalytics:(nullable id<FIRAnalyticsInterop>)analytics |
181 | 182 | withInstanceID:(FIRInstanceID *)instanceID |
182 | | - withUserDefaults:(NSUserDefaults *)defaults { |
| 183 | + withUserDefaults:(GULUserDefaults *)defaults { |
183 | 184 | self = [super init]; |
184 | 185 | if (self != nil) { |
185 | 186 | _loggedMessageIDs = [NSMutableSet set]; |
@@ -214,7 +215,7 @@ + (void)load { |
214 | 215 | id<FIRAnalyticsInterop> analytics = FIR_COMPONENT(FIRAnalyticsInterop, container); |
215 | 216 | return [[FIRMessaging alloc] initWithAnalytics:analytics |
216 | 217 | withInstanceID:[FIRInstanceID instanceID] |
217 | | - withUserDefaults:[NSUserDefaults standardUserDefaults]]; |
| 218 | + withUserDefaults:[GULUserDefaults standardUserDefaults]]; |
218 | 219 | }; |
219 | 220 | FIRComponent *messagingProvider = |
220 | 221 | [FIRComponent componentWithProtocol:@protocol(FIRMessagingInstanceProvider) |
|
0 commit comments