diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-06 15:10:29 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-06 15:10:29 +0300 |
commit | 5564275a0b378298dc6281599cbfe71a937109ff (patch) | |
tree | a468e1e60046356410219c35c23a8a428c5e2c5e /lib/gitlab/auth.rb | |
parent | d87918510a866a5fcbbc2f899ad65c6938ebf5f5 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/auth.rb')
-rw-r--r-- | lib/gitlab/auth.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/auth.rb b/lib/gitlab/auth.rb index 821c68dbedc..1329357d0b8 100644 --- a/lib/gitlab/auth.rb +++ b/lib/gitlab/auth.rb @@ -49,7 +49,7 @@ module Gitlab lfs_token_check(login, password, project) || oauth_access_token_check(login, password) || personal_access_token_check(password) || - deploy_token_check(login, password) || + deploy_token_check(login, password, project) || user_with_password_for_git(login, password) || Gitlab::Auth::Result.new @@ -208,7 +208,7 @@ module Gitlab end.uniq end - def deploy_token_check(login, password) + def deploy_token_check(login, password, project) return unless password.present? token = DeployToken.active.find_by_token(password) @@ -219,7 +219,7 @@ module Gitlab scopes = abilities_for_scopes(token.scopes) if valid_scoped_token?(token, all_available_scopes) - Gitlab::Auth::Result.new(token, token.project, :deploy_token, scopes) + Gitlab::Auth::Result.new(token, project, :deploy_token, scopes) end end |