Recently met a problem when doing the project, after the login user information is saved in the user model, makes the model after log out=nil, but in fact, this is just a fake logged on user token still exist, but there is no NSUserDefult inside, after restart the application, token disappear, how to solve this kind of situation, I would like to ask about for two or three weeks
CodePudding user response:
Do you need to elaborate on it? Read your narrative is I understand the needs of the token, can't really quit login, is that right? If so can you tell me the token is returned by the server or client?
CodePudding user response:
This token is given by the server stored in the local user information in such a model, in the operation of the log out, just let this model=nil, but as a matter of fact at the time of request interface, the client will still be attached to request token
CodePudding user response:
Token is the server to the you put a token into a property of the model, the model=nil haven't got the token request there will be no token You said don't have my token NSUserDefult after that your request is token is which come of?