javascript - Parse PHP SDK, returns the same session token on every login -


I try to logout the user at the REST API and the user "becomes" in the logout process. But when I log in with the parse after logging in, I get the same session token with the previous session. Has this happened or am I doing something wrong?

Here is my logout code snippet

  public function postLogout () {$ input = input :: all}; $ Message = ['required' = & gt; ': Attribute can not be empty', 'invalidToken' = & gt; 'Token is invalid The user has not already logged out or logged in. ']; $ Validator = verifier :: create ($ input, ['sessionToken' = & gt; 'required',], $ message); {$ Validator- & gt; fails ()) {Return response: JSON (['status' = & gt; 'error', 'message' = & gt; 'request is not valid', 'error' = & Gt; $ validator - & gt; message () - & gt; all ()]); } Else {try {$ user = ParseUser :: become ($ input ['sessionToken']); } {// token can not be validated Return response :: Jason (['Status' => 'Error', 'Message' = & gt; $ Message ['Invalid Token'], 'Error' = & gt; [$ ex-> getMessage ()]]); } Try {$ User: logOut (); Return Feedback: Jason (['Status' => 'Success', 'Message' = & gt; 'Logout']); } [$ Ex- (Expiration: $ Ex-) {Return Praction: JSON (['Status' = & gt; 'Error', 'Message' = & gt; 'Logout Error', 'Error' => [$ ex- & Gt; getMessage)]]); }}}  

I am using laravel 4.2 with parse PHP sdk. Thanks so much in advance.


Comments