Merge branch 'master' of github.com:gitlabhq/gitlabhq

This commit is contained in:
Dmitriy Zaporozhets 2015-03-07 11:24:21 -08:00
commit 1475cb9aaa
3 changed files with 6 additions and 3 deletions

View File

@ -15,7 +15,7 @@ class @EditBlob
$(".js-commit-button").click ->
$("#file-content").val editor.getValue()
$(".file-editor form").submit()
return
return false
editModePanes = $(".js-edit-mode-pane")
editModeLinks = $(".js-edit-mode a")

View File

@ -15,7 +15,7 @@ class @NewBlob
$(".js-commit-button").click ->
$("#file-content").val editor.getValue()
$(".file-editor form").submit()
return
return false
editor: ->
return @editor

View File

@ -83,7 +83,10 @@ module API
end
def authenticate_by_gitlab_shell_token!
unauthorized! unless secret_token == params['secret_token'].try(:chomp)
input = params['secret_token'].try(:chomp)
unless Devise.secure_compare(secret_token, input)
unauthorized!
end
end
def authenticated_as_admin!