Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

Commit

Permalink
Adding safety check: Name can be nil in case of facebook login
Browse files Browse the repository at this point in the history
  • Loading branch information
saeedbashir committed Jun 25, 2018
1 parent d9e4442 commit f316856
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Source/OEXUserDetails.m
Expand Up @@ -60,6 +60,10 @@ - (id)initWithUserDictionary:(NSDictionary*)userDetailsDictionary {
_userId = [userDetailsDictionary objectForKey:OEXUserDetailsUserIdKey];
_name = [userDetailsDictionary objectForKey:OEXUserDetailsNameKey];
_url = [userDetailsDictionary objectForKey:OEXUserDetailsUrlKey];

if ([_name isKindOfClass:[NSNull class]]) {
_name = @"";
}
}

return self;
Expand Down

0 comments on commit f316856

Please sign in to comment.