MPCheckpoint
[UPDATED] Refactoring of checkpoints.
This commit is contained in:
parent
efcfbe2584
commit
c0d57b5561
@ -126,13 +126,7 @@ static NSDictionary *keyQuery(MPUserEntity *user) {
|
|||||||
if (!tryKey) {
|
if (!tryKey) {
|
||||||
if (password) {
|
if (password) {
|
||||||
inf(@"Login failed for: %@", user.userID);
|
inf(@"Login failed for: %@", user.userID);
|
||||||
|
MPCheckpoint( MPCheckpointSignInFailed, nil );
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
|
||||||
[TestFlight passCheckpoint:MPCheckpointSignInFailed];
|
|
||||||
#endif
|
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointSignInFailed attributes:nil];
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return NO;
|
return NO;
|
||||||
@ -164,12 +158,7 @@ static NSDictionary *keyQuery(MPUserEntity *user) {
|
|||||||
self.activeUser = user;
|
self.activeUser = user;
|
||||||
|
|
||||||
[[NSNotificationCenter defaultCenter] postNotificationName:MPSignedInNotification object:self];
|
[[NSNotificationCenter defaultCenter] postNotificationName:MPSignedInNotification object:self];
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointSignedIn, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointSignedIn];
|
|
||||||
#endif
|
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointSignedIn attributes:nil];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
|
@ -333,15 +333,9 @@ PearlAssociatedObjectProperty(NSManagedObjectContext*, MainManagedObjectContext,
|
|||||||
isCloud:(BOOL)isCloudStore {
|
isCloud:(BOOL)isCloudStore {
|
||||||
|
|
||||||
inf(@"Using iCloud? %@", @(isCloudStore));
|
inf(@"Using iCloud? %@", @(isCloudStore));
|
||||||
|
MPCheckpoint( MPCheckpointCloud, @{
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
@"enabled" : @(isCloudStore)
|
||||||
[TestFlight passCheckpoint:isCloudStore? MPCheckpointCloudEnabled: MPCheckpointCloudDisabled];
|
} );
|
||||||
#endif
|
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointCloud attributes:@{
|
|
||||||
@"enabled": @(isCloudStore)
|
|
||||||
}];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Create our contexts.
|
// Create our contexts.
|
||||||
NSManagedObjectContext *privateManagedObjectContext = [[NSManagedObjectContext alloc] initWithConcurrencyType:NSPrivateQueueConcurrencyType];
|
NSManagedObjectContext *privateManagedObjectContext = [[NSManagedObjectContext alloc] initWithConcurrencyType:NSPrivateQueueConcurrencyType];
|
||||||
@ -365,17 +359,11 @@ PearlAssociatedObjectProperty(NSManagedObjectContext*, MainManagedObjectContext,
|
|||||||
context:(id)context {
|
context:(id)context {
|
||||||
|
|
||||||
err(@"[StoreManager] ERROR: cause=%d, context=%@, error=%@", cause, context, error);
|
err(@"[StoreManager] ERROR: cause=%d, context=%@, error=%@", cause, context, error);
|
||||||
|
MPCheckpoint( MPCheckpointMPErrorUbiquity, @{
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
|
||||||
[TestFlight passCheckpoint:PearlString( MPCheckpointMPErrorUbiquity @"_%d", cause )];
|
|
||||||
#endif
|
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointMPErrorUbiquity attributes:@{
|
|
||||||
@"cause" : @(cause),
|
@"cause" : @(cause),
|
||||||
@"error.domain" : error.domain,
|
@"error.domain" : error.domain,
|
||||||
@"error.code" : @(error.code)
|
@"error.code" : @(error.code)
|
||||||
}];
|
} );
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (BOOL)ubiquityStoreManager:(UbiquityStoreManager *)manager handleCloudContentCorruptionWithHealthyStore:(BOOL)storeHealthy {
|
- (BOOL)ubiquityStoreManager:(UbiquityStoreManager *)manager handleCloudContentCorruptionWithHealthyStore:(BOOL)storeHealthy {
|
||||||
@ -622,12 +610,7 @@ PearlAssociatedObjectProperty(NSManagedObjectContext*, MainManagedObjectContext,
|
|||||||
}
|
}
|
||||||
|
|
||||||
inf(@"Import completed successfully.");
|
inf(@"Import completed successfully.");
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointSitesImported, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointSitesImported];
|
|
||||||
#endif
|
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointSitesImported attributes:nil];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return MPImportResultSuccess;
|
return MPImportResultSuccess;
|
||||||
}
|
}
|
||||||
@ -683,12 +666,9 @@ PearlAssociatedObjectProperty(NSManagedObjectContext*, MainManagedObjectContext,
|
|||||||
? content: @""];
|
? content: @""];
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointSitesExported, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointSitesExported];
|
@"showPasswords" : @(showPasswords)
|
||||||
#endif
|
} );
|
||||||
#ifdef LOCALYTICS
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointSitesExported attributes:nil];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return export;
|
return export;
|
||||||
}
|
}
|
||||||
|
@ -61,18 +61,22 @@ typedef enum {
|
|||||||
#define MPCheckpointSignedIn @"MPCheckpointSignedIn"
|
#define MPCheckpointSignedIn @"MPCheckpointSignedIn"
|
||||||
#define MPCheckpointConfig @"MPCheckpointConfig"
|
#define MPCheckpointConfig @"MPCheckpointConfig"
|
||||||
#define MPCheckpointCloud @"MPCheckpointCloud"
|
#define MPCheckpointCloud @"MPCheckpointCloud"
|
||||||
#define MPCheckpointCloudEnabled @"MPCheckpointCloudEnabled"
|
|
||||||
#define MPCheckpointCloudDisabled @"MPCheckpointCloudDisabled"
|
|
||||||
#define MPCheckpointSitesImported @"MPCheckpointSitesImported"
|
#define MPCheckpointSitesImported @"MPCheckpointSitesImported"
|
||||||
#define MPCheckpointSitesExported @"MPCheckpointSitesExported"
|
#define MPCheckpointSitesExported @"MPCheckpointSitesExported"
|
||||||
#define MPCheckpointExplicitMigration @"MPCheckpointExplicitMigration"
|
#define MPCheckpointExplicitMigration @"MPCheckpointExplicitMigration"
|
||||||
#define MPCheckpointReview @"MPCheckpointReview"
|
#define MPCheckpointReview @"MPCheckpointReview"
|
||||||
#define MPCheckpointApps @"MPCheckpointApps"
|
#define MPCheckpointApps @"MPCheckpointApps"
|
||||||
#define MPCheckpointAppGorillas @"MPCheckpointAppGorillas"
|
#define MPCheckpointApp @"MPCheckpointApp"
|
||||||
#define MPCheckpointAppDeBlock @"MPCheckpointAppDeBlock"
|
|
||||||
|
|
||||||
#define MPSignedInNotification @"MPSignedInNotification"
|
#define MPSignedInNotification @"MPSignedInNotification"
|
||||||
#define MPSignedOutNotification @"MPSignedOutNotification"
|
#define MPSignedOutNotification @"MPSignedOutNotification"
|
||||||
#define MPKeyForgottenNotification @"MPKeyForgottenNotification"
|
#define MPKeyForgottenNotification @"MPKeyForgottenNotification"
|
||||||
#define MPElementUpdatedNotification @"MPElementUpdatedNotification"
|
#define MPElementUpdatedNotification @"MPElementUpdatedNotification"
|
||||||
#define MPCheckConfigNotification @"MPCheckConfigNotification"
|
#define MPCheckConfigNotification @"MPCheckConfigNotification"
|
||||||
|
|
||||||
|
static void MPCheckpoint(NSString *checkpoint, NSDictionary *attributes) {
|
||||||
|
|
||||||
|
#ifdef LOCALYTICS
|
||||||
|
[[LocalyticsSession sharedLocalyticsSession] tagEvent:checkpoint attributes:attributes];
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
@ -48,10 +48,10 @@
|
|||||||
#endif
|
#endif
|
||||||
[TestFlight addCustomEnvironmentInformation:@"Anonymous" forKey:@"username"];
|
[TestFlight addCustomEnvironmentInformation:@"Anonymous" forKey:@"username"];
|
||||||
[TestFlight addCustomEnvironmentInformation:[PearlKeyChain deviceIdentifier] forKey:@"deviceIdentifier"];
|
[TestFlight addCustomEnvironmentInformation:[PearlKeyChain deviceIdentifier] forKey:@"deviceIdentifier"];
|
||||||
[TestFlight setOptions:[NSDictionary dictionaryWithObjectsAndKeys:
|
[TestFlight setOptions:@{
|
||||||
[NSNumber numberWithBool:NO], @"logToConsole",
|
@"logToConsole" : @NO,
|
||||||
[NSNumber numberWithBool:NO], @"logToSTDERR",
|
@"logToSTDERR" : @NO
|
||||||
nil]];
|
}];
|
||||||
[TestFlight takeOff:testFlightToken];
|
[TestFlight takeOff:testFlightToken];
|
||||||
[[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) {
|
[[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) {
|
||||||
PearlLogLevel level = PearlLogLevelWarn;
|
PearlLogLevel level = PearlLogLevelWarn;
|
||||||
@ -120,11 +120,10 @@
|
|||||||
[[LocalyticsSession sharedLocalyticsSession] upload];
|
[[LocalyticsSession sharedLocalyticsSession] upload];
|
||||||
[[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) {
|
[[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) {
|
||||||
if (message.level >= PearlLogLevelWarn)
|
if (message.level >= PearlLogLevelWarn)
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:@"Problem"
|
MPCheckpoint( @"Problem", @{
|
||||||
attributes:@{
|
@"level" : @(PearlLogLevelStr( message.level )),
|
||||||
@"level": @(PearlLogLevelStr(message.level)),
|
@"message" : message.message
|
||||||
@"message": message.message
|
} );
|
||||||
}];
|
|
||||||
|
|
||||||
return YES;
|
return YES;
|
||||||
}];
|
}];
|
||||||
@ -220,10 +219,8 @@
|
|||||||
forKey:@"askForReviews"];
|
forKey:@"askForReviews"];
|
||||||
[TestFlight addCustomEnvironmentInformation:[[PearlConfig get].reviewAfterLaunches description] forKey:@"reviewAfterLaunches"];
|
[TestFlight addCustomEnvironmentInformation:[[PearlConfig get].reviewAfterLaunches description] forKey:@"reviewAfterLaunches"];
|
||||||
[TestFlight addCustomEnvironmentInformation:[PearlConfig get].reviewedVersion forKey:@"reviewedVersion"];
|
[TestFlight addCustomEnvironmentInformation:[PearlConfig get].reviewedVersion forKey:@"reviewedVersion"];
|
||||||
|
|
||||||
[TestFlight passCheckpoint:MPCheckpointConfig];
|
|
||||||
#endif
|
#endif
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointConfig attributes:@{
|
MPCheckpoint( MPCheckpointConfig, @{
|
||||||
@"rememberLogin" : [[MPConfig get].rememberLogin boolValue]? @"YES": @"NO",
|
@"rememberLogin" : [[MPConfig get].rememberLogin boolValue]? @"YES": @"NO",
|
||||||
@"iCloud" : [self storeManager].cloudEnabled? @"YES": @"NO",
|
@"iCloud" : [self storeManager].cloudEnabled? @"YES": @"NO",
|
||||||
@"iCloudDecided" : [[MPConfig get].iCloudDecided boolValue]? @"YES": @"NO",
|
@"iCloudDecided" : [[MPConfig get].iCloudDecided boolValue]? @"YES": @"NO",
|
||||||
@ -235,7 +232,7 @@
|
|||||||
@"askForReviews" : [[PearlConfig get].askForReviews boolValue]? @"YES": @"NO",
|
@"askForReviews" : [[PearlConfig get].askForReviews boolValue]? @"YES": @"NO",
|
||||||
@"reviewAfterLaunches" : NilToNSNull([[PearlConfig get].reviewAfterLaunches description]),
|
@"reviewAfterLaunches" : NilToNSNull([[PearlConfig get].reviewAfterLaunches description]),
|
||||||
@"reviewedVersion" : NilToNSNull([PearlConfig get].reviewedVersion)
|
@"reviewedVersion" : NilToNSNull([PearlConfig get].reviewedVersion)
|
||||||
}];
|
} );
|
||||||
}
|
}
|
||||||
}];
|
}];
|
||||||
[[NSNotificationCenter defaultCenter] addObserverForName:kIASKAppSettingChanged object:nil queue:nil
|
[[NSNotificationCenter defaultCenter] addObserverForName:kIASKAppSettingChanged object:nil queue:nil
|
||||||
@ -429,20 +426,14 @@
|
|||||||
|
|
||||||
[self.navigationController performSegueWithIdentifier:@"MP_Guide" sender:self];
|
[self.navigationController performSegueWithIdentifier:@"MP_Guide" sender:self];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointShowGuide, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointShowGuide];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointShowGuide attributes:nil];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)showSetup {
|
- (void)showSetup {
|
||||||
|
|
||||||
[self.navigationController performSegueWithIdentifier:@"MP_Setup" sender:self];
|
[self.navigationController performSegueWithIdentifier:@"MP_Setup" sender:self];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointShowSetup, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointShowSetup];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointShowSetup attributes:nil];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)showFeedback {
|
- (void)showFeedback {
|
||||||
@ -452,10 +443,7 @@
|
|||||||
|
|
||||||
- (void)showReview {
|
- (void)showReview {
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointReview, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointReview];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointReview attributes:nil];
|
|
||||||
|
|
||||||
[super showReview];
|
[super showReview];
|
||||||
}
|
}
|
||||||
@ -605,10 +593,7 @@
|
|||||||
if (didReset)
|
if (didReset)
|
||||||
didReset();
|
didReset();
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointChangeMP, nil );
|
||||||
[TestFlight passCheckpoint:MPCheckpointChangeMP];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointChangeMP attributes:nil];
|
|
||||||
}
|
}
|
||||||
cancelTitle:[PearlStrings get].commonButtonAbort
|
cancelTitle:[PearlStrings get].commonButtonAbort
|
||||||
otherTitles:[PearlStrings get].commonButtonContinue, nil];
|
otherTitles:[PearlStrings get].commonButtonContinue, nil];
|
||||||
|
@ -25,20 +25,18 @@
|
|||||||
|
|
||||||
- (IBAction)gorillas:(UIButton *)sender {
|
- (IBAction)gorillas:(UIButton *)sender {
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointApp, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointAppGorillas];
|
@"app" : @"gorillas"
|
||||||
#endif
|
} );
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointAppGorillas attributes:nil];
|
|
||||||
|
|
||||||
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://itunes.apple.com/app/lyndir/gorillas/id302275459?mt=8"]];
|
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://itunes.apple.com/app/lyndir/gorillas/id302275459?mt=8"]];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (IBAction)deblock:(UIButton *)sender {
|
- (IBAction)deblock:(UIButton *)sender {
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointApp, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointAppDeBlock];
|
@"app": @"deblock"
|
||||||
#endif
|
} );
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointAppDeBlock attributes:nil];
|
|
||||||
|
|
||||||
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://itunes.apple.com/app/lyndir/deblock/id325058485?mt=8"]];
|
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://itunes.apple.com/app/lyndir/deblock/id325058485?mt=8"]];
|
||||||
}
|
}
|
||||||
|
@ -66,11 +66,7 @@
|
|||||||
- (void)viewWillAppear:(BOOL)animated {
|
- (void)viewWillAppear:(BOOL)animated {
|
||||||
|
|
||||||
[[UIApplication sharedApplication] setStatusBarHidden:YES withAnimation:UIStatusBarAnimationSlide];
|
[[UIApplication sharedApplication] setStatusBarHidden:YES withAnimation:UIStatusBarAnimationSlide];
|
||||||
|
MPCheckpoint( MPCheckpointApps, nil );
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
|
||||||
[TestFlight passCheckpoint:MPCheckpointApps];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointApps attributes:nil];
|
|
||||||
|
|
||||||
[self.pageViewController setViewControllers:@[ [self.pageVCs objectAtIndex:1] ] direction:UIPageViewControllerNavigationDirectionForward
|
[self.pageViewController setViewControllers:@[ [self.pageVCs objectAtIndex:1] ] direction:UIPageViewControllerNavigationDirectionForward
|
||||||
animated:NO completion:nil];
|
animated:NO completion:nil];
|
||||||
|
@ -289,13 +289,10 @@ forRowAtIndexPath:(NSIndexPath *)indexPath {
|
|||||||
[element.managedObjectContext deleteObject:element];
|
[element.managedObjectContext deleteObject:element];
|
||||||
[element.managedObjectContext saveToStore];
|
[element.managedObjectContext saveToStore];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointDeleteElement, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointDeleteElement];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointDeleteElement attributes:@{
|
|
||||||
@"type" : element.typeName,
|
@"type" : element.typeName,
|
||||||
@"version" : @(element.version)
|
@"version" : @(element.version)
|
||||||
}];
|
});
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -310,10 +310,9 @@
|
|||||||
|
|
||||||
- (void)setHelpChapter:(NSString *)chapter {
|
- (void)setHelpChapter:(NSString *)chapter {
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointHelpChapter, @{
|
||||||
[TestFlight passCheckpoint:PearlString(MPCheckpointHelpChapter @"_%@", chapter)];
|
@"chapter" : chapter
|
||||||
#endif
|
} );
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointHelpChapter attributes:@{@"chapter": chapter}];
|
|
||||||
|
|
||||||
dispatch_async(dispatch_get_main_queue(), ^{
|
dispatch_async(dispatch_get_main_queue(), ^{
|
||||||
NSURL *url = [NSURL URLWithString:[@"#" stringByAppendingString:chapter]
|
NSURL *url = [NSURL URLWithString:[@"#" stringByAppendingString:chapter]
|
||||||
@ -471,11 +470,11 @@
|
|||||||
|
|
||||||
[self showContentTip:@"Copied!" withIcon:nil];
|
[self showContentTip:@"Copied!" withIcon:nil];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointCopyToPasteboard, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointCopyToPasteboard];
|
@"type" : activeElement.typeName,
|
||||||
#endif
|
@"version" : @(activeElement.version),
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointCopyToPasteboard attributes:@{@"type" : activeElement.typeName,
|
@"emergency" : @NO
|
||||||
@"version" : @(activeElement.version)}];
|
} );
|
||||||
}
|
}
|
||||||
|
|
||||||
- (IBAction)copyLoginName:(UITapGestureRecognizer *)sender {
|
- (IBAction)copyLoginName:(UITapGestureRecognizer *)sender {
|
||||||
@ -489,12 +488,10 @@
|
|||||||
|
|
||||||
[self showLoginNameTip:@"Copied!"];
|
[self showLoginNameTip:@"Copied!"];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointCopyLoginNameToPasteboard, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointCopyLoginNameToPasteboard];
|
@"type" : activeElement.typeName,
|
||||||
#endif
|
@"version" : @(activeElement.version)
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointCopyLoginNameToPasteboard
|
} );
|
||||||
attributes:@{@"type" : activeElement.typeName,
|
|
||||||
@"version" : @(activeElement.version)}];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (IBAction)incrementPasswordCounter {
|
- (IBAction)incrementPasswordCounter {
|
||||||
@ -510,16 +507,16 @@
|
|||||||
err(@"Cannot increment password counter: Element is not generated: %@", activeElement.name);
|
err(@"Cannot increment password counter: Element is not generated: %@", activeElement.name);
|
||||||
return NO;
|
return NO;
|
||||||
}
|
}
|
||||||
|
MPElementGeneratedEntity *activeGeneratedElement = (MPElementGeneratedEntity *)activeElement;
|
||||||
|
|
||||||
inf(@"Incrementing password counter for: %@", activeElement.name);
|
inf(@"Incrementing password counter for: %@", activeGeneratedElement.name);
|
||||||
++((MPElementGeneratedEntity *)activeElement).counter;
|
++activeGeneratedElement.counter;
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointIncrementPasswordCounter, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointIncrementPasswordCounter];
|
@"type" : activeGeneratedElement.typeName,
|
||||||
#endif
|
@"version" : @(activeGeneratedElement.version),
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointIncrementPasswordCounter
|
@"counter" : @(activeGeneratedElement.counter)
|
||||||
attributes:@{@"type": activeElement.typeName,
|
} );
|
||||||
@"version": @(activeElement.version)}];
|
|
||||||
return YES;
|
return YES;
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
@ -547,12 +544,10 @@
|
|||||||
inf(@"Resetting password counter for: %@", activeElement_.name);
|
inf(@"Resetting password counter for: %@", activeElement_.name);
|
||||||
((MPElementGeneratedEntity *)activeElement_).counter = 1;
|
((MPElementGeneratedEntity *)activeElement_).counter = 1;
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointResetPasswordCounter, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointResetPasswordCounter];
|
@"type" : activeElement_.typeName,
|
||||||
#endif
|
@"version" : @(activeElement_.version)
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointResetPasswordCounter
|
} );
|
||||||
attributes:@{@"type": activeElement_.typeName,
|
|
||||||
@"version": @(activeElement_.version)}];
|
|
||||||
return YES;
|
return YES;
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
@ -570,11 +565,10 @@
|
|||||||
self.loginNameField.enabled = YES;
|
self.loginNameField.enabled = YES;
|
||||||
[self.loginNameField becomeFirstResponder];
|
[self.loginNameField becomeFirstResponder];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointEditLoginName, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointEditLoginName];
|
@"type" : activeElement.typeName,
|
||||||
#endif
|
@"version" : @(activeElement.version)
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointEditLoginName attributes:@{@"type" : activeElement.typeName,
|
} );
|
||||||
@"version" : @(activeElement.version)}];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)changeActiveElementWithWarning:(NSString *)warning do:(BOOL (^)(MPElementEntity *activeElement))task; {
|
- (void)changeActiveElementWithWarning:(NSString *)warning do:(BOOL (^)(MPElementEntity *activeElement))task; {
|
||||||
@ -644,11 +638,10 @@
|
|||||||
self.contentField.enabled = YES;
|
self.contentField.enabled = YES;
|
||||||
[self.contentField becomeFirstResponder];
|
[self.contentField becomeFirstResponder];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointEditPassword, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointEditPassword];
|
@"type" : activeElement.typeName,
|
||||||
#endif
|
@"version" : @(activeElement.version)
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointEditPassword attributes:@{@"type" : activeElement.typeName,
|
} );
|
||||||
@"version" : @(activeElement.version)}];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (IBAction)upgradePassword {
|
- (IBAction)upgradePassword {
|
||||||
@ -670,13 +663,10 @@
|
|||||||
inf(@"Explicitly migrating element: %@", activeElement_);
|
inf(@"Explicitly migrating element: %@", activeElement_);
|
||||||
[activeElement_ migrateExplicitly:YES];
|
[activeElement_ migrateExplicitly:YES];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointExplicitMigration, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointExplicitMigration];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointExplicitMigration attributes:@{
|
|
||||||
@"type" : activeElement_.typeName,
|
@"type" : activeElement_.typeName,
|
||||||
@"version" : @(activeElement_.version)
|
@"version" : @(activeElement_.version)
|
||||||
}];
|
} );
|
||||||
return YES;
|
return YES;
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
@ -849,12 +839,11 @@
|
|||||||
[self.searchDisplayController setActive:NO animated:YES];
|
[self.searchDisplayController setActive:NO animated:YES];
|
||||||
self.searchDisplayController.searchBar.text = activeElement.name;
|
self.searchDisplayController.searchBar.text = activeElement.name;
|
||||||
|
|
||||||
[[NSNotificationCenter defaultCenter] postNotificationName:MPElementUpdatedNotification object:activeElement.objectID];
|
MPCheckpoint( MPCheckpointUseType, @{
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
@"type" : activeElement.typeName,
|
||||||
[TestFlight passCheckpoint:PearlString(MPCheckpointUseType @"_%@", activeElement.typeShortName)];
|
@"version" : @(activeElement.version)
|
||||||
#endif
|
} );
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointUseType attributes:@{@"type" : activeElement.typeName,
|
|
||||||
@"version" : @(activeElement.version)}];
|
|
||||||
[self updateAnimated:YES];
|
[self updateAnimated:YES];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -897,14 +897,11 @@
|
|||||||
}
|
}
|
||||||
}];
|
}];
|
||||||
|
|
||||||
#ifdef TESTFLIGHT_SDK_VERSION
|
MPCheckpoint( MPCheckpointCopyToPasteboard, @{
|
||||||
[TestFlight passCheckpoint:MPCheckpointCopyToPasteboard];
|
|
||||||
#endif
|
|
||||||
[[LocalyticsSession sharedLocalyticsSession] tagEvent:MPCheckpointCopyToPasteboard attributes:@{
|
|
||||||
@"type" : [MPAlgorithmDefault nameOfType:self.emergencyType],
|
@"type" : [MPAlgorithmDefault nameOfType:self.emergencyType],
|
||||||
@"version" : @MPAlgorithmDefaultVersion,
|
@"version" : @MPAlgorithmDefaultVersion,
|
||||||
@"emergency" : @YES,
|
@"emergency" : @YES,
|
||||||
}];
|
} );
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)emergencyCloseAnimated:(BOOL)animated {
|
- (void)emergencyCloseAnimated:(BOOL)animated {
|
||||||
|
Loading…
Reference in New Issue
Block a user