{"action":"created","issue":{"url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/686","repository_url":"https://api.github.com/repos/thephpleague/oauth2-server","labels_url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/686/labels{/name}","comments_url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/686/comments","events_url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/686/events","html_url":"https://github.com/thephpleague/oauth2-server/issues/686","id":190353257,"number":686,"title":"How can I delay token revocation?","user":{"login":"ServiceTo","id":4366064,"avatar_url":"https://avatars.githubusercontent.com/u/4366064?v=3","gravatar_id":"","url":"https://api.github.com/users/ServiceTo","html_url":"https://github.com/ServiceTo","followers_url":"https://api.github.com/users/ServiceTo/followers","following_url":"https://api.github.com/users/ServiceTo/following{/other_user}","gists_url":"https://api.github.com/users/ServiceTo/gists{/gist_id}","starred_url":"https://api.github.com/users/ServiceTo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ServiceTo/subscriptions","organizations_url":"https://api.github.com/users/ServiceTo/orgs","repos_url":"https://api.github.com/users/ServiceTo/repos","events_url":"https://api.github.com/users/ServiceTo/events{/privacy}","received_events_url":"https://api.github.com/users/ServiceTo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-18T15:55:35Z","updated_at":"2016-11-18T15:57:15Z","closed_at":null,"body":"I'm writing a chatty ember-cli front-end app and I'm finding that it's sending multiple requests asynchronously to my Laravel back-end and what's happening is the token is being revoked in the same second as another request comes in so the new token hasn't made it back to the front-end for use yet. This provides an exception on the second request and the user has to log in again.\r\n\r\nWhat is the best way to delay these lines from running in RefreshTokenGrant.php from respondToAccessTokenRequest() (without forking, if possible)\r\n\r\n// Expire old tokens\r\n$this->accessTokenRepository->revokeAccessToken($oldRefreshToken['access_token_id']);\r\n$this->refreshTokenRepository->revokeRefreshToken($oldRefreshToken['refresh_token_id']);\r\n\r\nThanks in advance for any advice"},"comment":{"url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/comments/261566853","html_url":"https://github.com/thephpleague/oauth2-server/issues/686#issuecomment-261566853","issue_url":"https://api.github.com/repos/thephpleague/oauth2-server/issues/686","id":261566853,"user":{"login":"alexbilbie","id":77991,"avatar_url":"https://avatars.githubusercontent.com/u/77991?v=3","gravatar_id":"","url":"https://api.github.com/users/alexbilbie","html_url":"https://github.com/alexbilbie","followers_url":"https://api.github.com/users/alexbilbie/followers","following_url":"https://api.github.com/users/alexbilbie/following{/other_user}","gists_url":"https://api.github.com/users/alexbilbie/gists{/gist_id}","starred_url":"https://api.github.com/users/alexbilbie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexbilbie/subscriptions","organizations_url":"https://api.github.com/users/alexbilbie/orgs","repos_url":"https://api.github.com/users/alexbilbie/repos","events_url":"https://api.github.com/users/alexbilbie/events{/privacy}","received_events_url":"https://api.github.com/users/alexbilbie/received_events","type":"User","site_admin":false},"created_at":"2016-11-18T15:57:15Z","updated_at":"2016-11-18T15:57:15Z","body":"You're best bet it to probably add logic to the front end to correctly respond to invalid token errors and back-off for a moment until the frontend has got the new access token"}}
{"actor":{"display_login":"alexbilbie"}}