Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatricio Cano <suprnova32@gmail.com>2016-06-21 04:40:56 +0300
committerPatricio Cano <suprnova32@gmail.com>2016-07-06 00:54:22 +0300
commit7735ef86f0714a5b2a4cb4db8ec0471654563885 (patch)
tree5f56b0348da8870736339150b669069f84e43fd1 /app/helpers/button_helper.rb
parentea9d910c8bd2774cf48a5b6092704143a7505011 (diff)
Only allow Git Access on the allowed protocol
Diffstat (limited to 'app/helpers/button_helper.rb')
-rw-r--r--app/helpers/button_helper.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/helpers/button_helper.rb b/app/helpers/button_helper.rb
index 9051a493b9b..a64e96eaec9 100644
--- a/app/helpers/button_helper.rb
+++ b/app/helpers/button_helper.rb
@@ -40,7 +40,7 @@ module ButtonHelper
type: :button
end
- def http_clone_button(project)
+ def http_clone_button(project, placement = 'right')
klass = 'http-selector'
klass << ' has-tooltip' if current_user.try(:require_password?)
@@ -51,13 +51,13 @@ module ButtonHelper
href: project.http_url_to_repo,
data: {
html: true,
- placement: 'right',
+ placement: placement,
container: 'body',
title: "Set a password on your account<br>to pull or push via #{protocol}"
}
end
- def ssh_clone_button(project)
+ def ssh_clone_button(project, placement = 'right')
klass = 'ssh-selector'
klass << ' has-tooltip' if current_user.try(:require_ssh_key?)
@@ -66,7 +66,7 @@ module ButtonHelper
href: project.ssh_url_to_repo,
data: {
html: true,
- placement: 'right',
+ placement: placement,
container: 'body',
title: 'Add an SSH key to your profile<br>to pull or push via SSH.'
}