Skip to content

Commit

Permalink
fix: remove sync method, call initializeDeviceID from getDeviceId
Browse files Browse the repository at this point in the history
  • Loading branch information
bgiori committed Apr 4, 2024
1 parent 2e30d1c commit eca6cc2
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
4 changes: 0 additions & 4 deletions Sources/Amplitude/Amplitude.m
Original file line number Diff line number Diff line change
Expand Up @@ -1669,10 +1669,6 @@ - (NSString *)getAdSupportID {
}

- (NSString *)getDeviceId {
return self.deviceId;
}

- (NSString *)getDeviceIdSync {
return [self initializeDeviceId];
}

Expand Down
7 changes: 0 additions & 7 deletions Sources/Amplitude/Public/Amplitude.h
Original file line number Diff line number Diff line change
Expand Up @@ -726,13 +726,6 @@ typedef void (^AMPInitCompletionBlock)(void);
*/
- (NSString *)getDeviceId;

/**
Fetches the deviceId synchronously. This must be called after initialization, but will access the device ID from the storage or generate one if the asynchronous intialization function has not reached that point yet. The device ID is a unique identifier shared between multiple users using the same app on the same device.
@returns the deviceId.
*/
- (NSString *)getDeviceIdSync;

/**
Regenerates a new random deviceId for current user. Note: this is not recommended unless you know what you are doing. This can be used in conjunction with setUserId:nil to anonymize users after they log out. With a nil userId and a completely new deviceId, the current user would appear as a brand new user in dashboard.
Expand Down

0 comments on commit eca6cc2

Please sign in to comment.