Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not saving data swift 3 #163

Open
gaborcsontos opened this issue Dec 4, 2016 · 4 comments
Open

not saving data swift 3 #163

gaborcsontos opened this issue Dec 4, 2016 · 4 comments

Comments

@gaborcsontos
Copy link

Hello.

Currently I tried to implement the Locksmith, but I still get an error, while it's not saving any data.

`
do {
//Locksmith save usercredentials
try Locksmith.saveData(["user_Id": "12"], forUserAccount: "myUserAccount")

    }
        
    catch {
        print("didnt saved")
        //"could not save the data into keychain"
    }
    //retrieve datas from keychain
    let dictionary = Locksmith.loadDataForUserAccount("myUserAccount")`

Any ideas? Always getting nil and dictionary [String : Any]? 0 key/value pairs some at the console

@gaborcsontos
Copy link
Author

Well the issue is only on device. On simulator it works well. I enabled keychain sharing as well, but it not works on phone.. Any ideas?

@shingsoso
Copy link

same Problem ...
Any Help?

@gaborcsontos
Copy link
Author

Well. Now it is working, but actually I didn't know how exactly I was able to fix.

I read the documentation about keychain sharing.
If you enable keychain sharing it works on simulator.

What I did:
Went to developer profile, I created an AppId in the Certificates and a provisionary profile for the app. I removed my developer profile from the Xcode and added again(downloaded the new provisionary profile as well). After it started to work, but I am not sure, because of it.

@gaborcsontos
Copy link
Author

shingsoso does it work for you as well after doing what I wrote?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants