X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/15b104f4ff4614aa78c01180b6a9b89dd5a1400f..b0c90ed2b4f43b34e1830336205ff7f288807dba:/app/models/oauth_token.rb?ds=sidebyside diff --git a/app/models/oauth_token.rb b/app/models/oauth_token.rb index fd332723f..affdcdeb8 100644 --- a/app/models/oauth_token.rb +++ b/app/models/oauth_token.rb @@ -35,7 +35,7 @@ # oauth_tokens_user_id_fkey (user_id => users.id) # -class OauthToken < ActiveRecord::Base +class OauthToken < ApplicationRecord belongs_to :client_application belongs_to :user @@ -52,7 +52,7 @@ class OauthToken < ActiveRecord::Base end def invalidate! - update_attributes(:invalidated_at => Time.now) + update(:invalidated_at => Time.now) end def authorized?