diff options
author | Mayra Cabrera <mcabrera@gitlab.com> | 2018-07-23 12:23:08 +0300 |
---|---|---|
committer | Grzegorz Bizon <grzegorz@gitlab.com> | 2018-07-23 12:23:08 +0300 |
commit | f2c46672cae763bb213e8aa14253e5eea48c1064 (patch) | |
tree | 708ab3375268f826b01adb2ae79e590bcb9aabd1 /app/models | |
parent | d1f890e9e4c759b1b43b888c07127a05e38f53e5 (diff) |
Resolve "Deploy Tokens failed to clone LFS repository"
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/deploy_token.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/models/deploy_token.rb b/app/models/deploy_token.rb index 5082dc45368..7ab647abe93 100644 --- a/app/models/deploy_token.rb +++ b/app/models/deploy_token.rb @@ -27,7 +27,7 @@ class DeployToken < ActiveRecord::Base end def active? - !revoked + !revoked && expires_at > Date.today end def scopes @@ -58,6 +58,10 @@ class DeployToken < ActiveRecord::Base write_attribute(:expires_at, value.presence || Forever.date) end + def admin? + false + end + private def ensure_at_least_one_scope |