X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/0dba53c0232385f0fd080266f9a5ce3665426293..c798fe416a60eb25f8390ca8a5ab22126dfc7155:/app/models/user_token.rb?ds=inline diff --git a/app/models/user_token.rb b/app/models/user_token.rb index dda191187..3060b33ea 100644 --- a/app/models/user_token.rb +++ b/app/models/user_token.rb @@ -1,8 +1,14 @@ class UserToken < ActiveRecord::Base belongs_to :user + attr_accessible :referer + after_initialize :set_defaults + def expired? + expiry < Time.now + end + private def set_defaults