Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: identity v3 #180

Merged
merged 21 commits into from Jul 19, 2021
Merged

Feature: identity v3 #180

merged 21 commits into from Jul 19, 2021

Conversation

aboedo
Copy link
Member

@aboedo aboedo commented Apr 1, 2021

changes summary:

  • adds logIn and logOut methods
  • deprecates setAllowSharingAppStoreAccount, identify and reset methods

Requirements:

  • purchases-hybrid-common release with identity v3 support
  • purchases-ios release with identity v3 support
  • purchases-android release with identity v3 support

@aboedo aboedo added the HOLD label Apr 1, 2021
@aboedo aboedo self-assigned this Apr 1, 2021
@aboedo aboedo marked this pull request as draft April 2, 2021 18:04
@aboedo aboedo force-pushed the feature/identity_v3 branch 2 times, most recently from f3b34a5 to 8fb7d6b Compare April 9, 2021 17:56
Comment on lines +123 to +124
@override
bool operator ==(other) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

used for checks in tests

@@ -4,55 +4,61 @@

#import <PurchasesHybridCommon/PurchasesHybridCommon.h>


Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a lot of the stuff in this file is auto-formatting

Comment on lines +79 to 85
} else if ([@"logOut" isEqualToString:call.method]) {
[self logOutWithResult:result];
} else if ([@"reset" isEqualToString:call.method]) {
[self resetWithResult:result];
} else if ([@"logIn" isEqualToString:call.method]) {
[self logInAppUserID:arguments[@"appUserID"] result:result];
} else if ([@"identify" isEqualToString:call.method]) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new stuff here

Comment on lines +271 to +275
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these are to prevent xcode build warnings that show up for developers who use our SDK, even if it's internal to us

- (void)identify:(NSString *_Nullable)appUserID
result:(FlutterResult)result
{
- (void)logInAppUserID:(NSString * _Nullable)appUserID
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new stuff here

}

- (void)logOutWithResult:(FlutterResult)result {
[RCCommonFunctionality logOutWithCompletionBlock:[self getResponseCompletionBlock:result]];
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

end of new stuff

@@ -631,3 +667,16 @@ class IntroEligibility {
: status = IntroEligibilityStatus.values[map["status"]],
description = map["description"];
}

/// Class used to hold the result of the logIn method
class LogInResult {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

didn't know the best way to handle it in Flutter, it seemed like having a new type would be the cleanest.

@aboedo aboedo marked this pull request as ready for review April 9, 2021 18:23
@aboedo aboedo requested review from vegaro and beylmk April 9, 2021 18:24
Copy link
Contributor

@vegaro vegaro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Don 't forget to remove all the temporary dependencies stuff

@vegaro
Copy link
Contributor

vegaro commented Apr 9, 2021

oh just saw purchases-hybrid-common is merged with the temporary dependencies. Is the plan to merge this too and then remove the temporary development dependencies in a future PR?

@aboedo
Copy link
Member Author

aboedo commented Apr 9, 2021

yeah, that was my thinking, to have everything ready and merged and then in the release branch make sure to point to final versions

@aboedo aboedo removed the HOLD label Jul 19, 2021
Comment on lines +436 to +439
- (void)canMakePaymentsWithFeatures:(NSArray <NSNumber *>*)features result:(FlutterResult)result {
result(@([RCCommonFunctionality canMakePaymentsWithFeatures:features]));
}

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not new, just formatted and moved to after collectDeviceIdentifiersWithResult since that one is related to attribution

… the local version, updated calls to identity methods to identity v3 in magicWeather
@aboedo aboedo merged commit 2c28956 into develop Jul 19, 2021
@aboedo aboedo deleted the feature/identity_v3 branch July 19, 2021 20:10
@aboedo aboedo mentioned this pull request Jul 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants