In my application, i want to store the date at which the app is started for the first time.
I'm using following code in application:didFinishLaunchingWithOptions method
NSDate* today = [NSDate date];
[[NSUserDefaults standardUserDefaults] registerDefaults: @{@"CONSCIENCE_START_DATE" : today}];
NSLog(@"%@", [[NSUserDefaults standardUserDefaults] objectForKey:@"CONSCIENCE_START_DATE"]);
But every time when i start the application, its printing the time at which the app is starting. Its not printing the date at which i started the app.
I tried to reset the simulator and ran the code again. Still no success. Can some one point me the error in my code please?