class Doorkeeper::OAuth::RefreshTokenRequest

def before_successful_response

def before_successful_response
  refresh_token.transaction do
    refresh_token.lock!
    raise Errors::InvalidGrantReuse if refresh_token.revoked?
    refresh_token.revoke unless refresh_token_revoked_on_use?
    create_access_token
  end
  super
end