Skip to content

Lockbox unarchiveObjectForKey: returns nil sometimes #54

@maxencecornu

Description

@maxencecornu

Hello,

I use LockBox to store a refresh token and some urls, but sometimes when I call [Lockbox unarchiveObjectForKey:myKey] it returns nil. I don't know why :/

Here is how I save the data : (the infos came from a WS call)

[Lockbox archiveObject:oauthDico[@"baseUrl"] forKey:kOAuthBaseUrl]; [Lockbox archiveObject:oauthDico[@"getTokenEndpoint"] forKey:kOAuthTokenEndPoint]; [Lockbox archiveObject:oauthDico[@"refreshTokenEndpoint"] forKey:kOAuthRefreshTokenEndPoint];`

and this is how I retrieve it :

NSString* requestUrl = [NSString stringWithFormat:@"%@%@", [Lockbox unarchiveObjectForKey:kOAuthBaseUrl], [Lockbox unarchiveObjectForKey:kOAuthTokenEndPoint]];

and as I told, sometimes, I didn't figured out when excatly, the unarchive method returns nil, which is very problematic for a login url :p

Thanks for your help
Max

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions