I am setting up some constants, one being an NSDate but receiving this wanring message:
Incompatible pointer types initializing NSDate *const __strong
with an expression of type NSString
Simple explanation of code (imp file):
NSDate *const kPAPUserBirthdayKey = @"fbBirthday";
Advanced explanation: I use a constants file as a singleton holding constant variables for the API i write to. For example the above which is a Date field which will hold the facebook users birthday when connecting to Facebook.
This is then later used in the following conversion:
// Convert the DOB string into Date format
NSDateFormatter* df = [[NSDateFormatter alloc] init];
[df setDateFormat:@"MM/dd/yyyy"];
NSDate* userDOB = [df dateFromString:user.birthday];
[[PFUser currentUser] setObject:userDOB forKey:kPAPUserBirthdayKey];
Can someone explain what the warning actually means and what should be changed here? I get the same error on the last line of the above?