Skip to content

Commit

Permalink
updated sample app to use identity v3
Browse files Browse the repository at this point in the history
  • Loading branch information
aboedo committed Apr 27, 2021
1 parent 38533b7 commit d3ba3ff
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ extension UserViewController {

#warning("Public-facing usernames aren't optimal for user ID's - you should use something non-guessable, like a non-public database ID. For more information, visit https://docs.revenuecat.com/docs/user-ids.")
/// - Call `identify` with the Purchases SDK with the unique user ID
Purchases.shared.identify(username) { (purchaserInfo, error) in
Purchases.shared.logIn(username) { (purchaserInfo, created, error) in
if let error = error {
self.present(UIAlertController.errorAlert(message: error.localizedDescription), animated: true, completion: nil)
}
Expand All @@ -92,7 +92,7 @@ extension UserViewController {
Note: Each time you call `reset`, a new installation will be logged in the RevenueCat dashboard as that metric tracks unique user ID's that are in-use. Since this method generates a new anonymous ID, it counts as a new user ID in-use.
*/
Purchases.shared.reset { (purchaserInfo, error) in
Purchases.shared.logOut { (purchaserInfo, error) in
if let error = error {
self.present(UIAlertController.errorAlert(message: error.localizedDescription), animated: true, completion: nil)
} else {
Expand Down

0 comments on commit d3ba3ff

Please sign in to comment.