diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2016-12-06 21:10:27 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2016-12-06 21:10:27 +0800 |
commit | 46d7c1d2b3cf87023cb6bcf40dd53aa79606d203 (patch) | |
tree | e55683af08a4b8204e288cc38d6b47b7ef7f4a28 /lib | |
parent | 1b150576d9de9096796f76e1635d27ddaa2b1dd5 (diff) | |
download | gitlab-ce-46d7c1d2b3cf87023cb6bcf40dd53aa79606d203.tar.gz |
Prefer guest_can_download_code? and fix typo
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/git_access.rb | 4 | ||||
-rw-r--r-- | lib/gitlab/git_access_wiki.rb | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/git_access.rb b/lib/gitlab/git_access.rb index d42879e38cd..412f42c6320 100644 --- a/lib/gitlab/git_access.rb +++ b/lib/gitlab/git_access.rb @@ -51,7 +51,7 @@ module Gitlab deploy_key.has_access_to?(project) elsif user user_can_download_code? || build_can_download_code? - end || guest_can_downlod_code? + end || guest_can_download_code? unless passed message = if deploy_key @@ -79,7 +79,7 @@ module Gitlab check_change_access!(changes) end - def guest_can_downlod_code? + def guest_can_download_code? Guest.can?(:download_code, project) end diff --git a/lib/gitlab/git_access_wiki.rb b/lib/gitlab/git_access_wiki.rb index 74171f4f90e..67eaa5e088d 100644 --- a/lib/gitlab/git_access_wiki.rb +++ b/lib/gitlab/git_access_wiki.rb @@ -1,6 +1,6 @@ module Gitlab class GitAccessWiki < GitAccess - def guest_can_downlod_code? + def guest_can_download_code? Guest.can?(:download_wiki_code, project) end |