{"id":17359607,"date":"2024-01-20T20:25:03","date_gmt":"2024-01-20T20:25:03","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/remove-refresh-token\/"},"modified":"2024-01-20T20:25:03","modified_gmt":"2024-01-20T20:25:03","slug":"remove-refresh-token","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/remove-refresh-token\/","title":{"rendered":"Remove refresh token"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">I just tried and deleted a test user from my wordpress site. The user was logged in and continued to use his refresh token to get new access tokens.<br \/>What is the best way to handle this?<\/p>\n\n\n\n<ul>\n<li>I expected you code to check if the user exists on a token refresh<\/li>\n\n\n\n<li>I assume I could use the wo_before_token_method hook and just die if the user doesn&#8217;t exist any more<\/li>\n\n\n\n<li>I assume I could just delete the user&#8217;s refresh tokens from the database when the user is deleted.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"template":"","class_list":["post-17359607","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/17359607","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/17359607\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=17359607"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}