Skip to content

Instantly share code, notes, and snippets.

@bitwit
Created February 20, 2014 20:27
Show Gist options
  • Save bitwit/9122514 to your computer and use it in GitHub Desktop.
Save bitwit/9122514 to your computer and use it in GitHub Desktop.
Only open RFRateMe after a # of app uses
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
int timesOpened = [defaults integerForKey:@"timesOpened"];
NSLog(@"App has been opened %d times", timesOpened);
if(timesOpened >= 4){
[RFRateMe showRateAlert];
}
[defaults setInteger:(timesOpened+1) forKey:@"timesOpened"];
[defaults synchronize];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment