FIX: Use existing UID instead of recreating one

This commit is contained in:
Marcos Rodriguez Vélez 2021-10-22 01:38:28 -04:00
parent cdea09dfca
commit c9b286fc10
No known key found for this signature in database
GPG key ID: 0D64671698D11C5C
2 changed files with 1 additions and 15 deletions

View file

@ -42,7 +42,6 @@ static void InitializeFlipper(UIApplication *application) {
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[Bugsnag start];
[self registerDefaultsFromSettingsBundle];
#if !TARGET_OS_MACCATALYST
#ifdef FB_SONARKIT_ENABLED
InitializeFlipper(application);
@ -79,19 +78,6 @@ static void InitializeFlipper(UIApplication *application) {
return YES;
}
#pragma NSUserDefaults
- (void)registerDefaultsFromSettingsBundle {
// this function writes default settings as settings
NSString *settingsBundle = [[NSBundle mainBundle] pathForResource:@"Settings" ofType:@"bundle"];
if(!settingsBundle) {
NSLog(@"Could not find Settings.bundle");
return;
}
[[NSUserDefaults standardUserDefaults] setValue:UIDevice.currentDevice.identifierForVendor.UUIDString forKey:@"uniqueid"];
[[NSUserDefaults standardUserDefaults] synchronize];
}
- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge
{
#if DEBUG

View file

@ -20,7 +20,7 @@
<key>Title</key>
<string>Unique ID</string>
<key>Key</key>
<string>uniqueid</string>
<string>deviceUID</string>
</dict>
</array>
</dict>