summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2017-06-09 14:34:10 +0000
committerRémy Coutable <remy@rymai.me>2017-06-09 14:34:10 +0000
commitce37a209c6394115eb77c01b877dfd3ae1a6e7e1 (patch)
treed24546b89574deb33b0df1237779d05a91bc8a5f /app
parent9fc9cd03a5381cc2cd8a72a89d67a04a6a5b8a9c (diff)
parentcb5a5eb89265f7261ecc97b6de5bd26ca092960c (diff)
downloadgitlab-ce-ce37a209c6394115eb77c01b877dfd3ae1a6e7e1.tar.gz
Merge branch 'pat-msg-on-auth-failure' into 'master'
Prompt user to create personal access token for Git over HTTP See merge request !11986
Diffstat (limited to 'app')
-rw-r--r--app/controllers/jwt_controller.rb2
-rw-r--r--app/controllers/projects/git_http_client_controller.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/jwt_controller.rb b/app/controllers/jwt_controller.rb
index c585d26df77..11db164b3fa 100644
--- a/app/controllers/jwt_controller.rb
+++ b/app/controllers/jwt_controller.rb
@@ -39,7 +39,7 @@ class JwtController < ApplicationController
errors: [
{ code: 'UNAUTHORIZED',
message: "HTTP Basic: Access denied\n" \
- "You have 2FA enabled, please use a personal access token for Git over HTTP.\n" \
+ "You must use a personal access token with 'api' scope for Git over HTTP.\n" \
"You can generate one at #{profile_personal_access_tokens_url}" }
]
}, status: 401
diff --git a/app/controllers/projects/git_http_client_controller.rb b/app/controllers/projects/git_http_client_controller.rb
index 7f3205a8001..928f17e6a8e 100644
--- a/app/controllers/projects/git_http_client_controller.rb
+++ b/app/controllers/projects/git_http_client_controller.rb
@@ -104,7 +104,7 @@ class Projects::GitHttpClientController < Projects::ApplicationController
def render_missing_personal_token
render plain: "HTTP Basic: Access denied\n" \
- "You have 2FA enabled, please use a personal access token for Git over HTTP.\n" \
+ "You must use a personal access token with 'api' scope for Git over HTTP.\n" \
"You can generate one at #{profile_personal_access_tokens_url}",
status: 401
end