diff options
Diffstat (limited to 'lib/gitlab/git/hook.rb')
-rw-r--r-- | lib/gitlab/git/hook.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/git/hook.rb b/lib/gitlab/git/hook.rb index 7c201c6169b..94ff5b4980a 100644 --- a/lib/gitlab/git/hook.rb +++ b/lib/gitlab/git/hook.rb @@ -11,7 +11,7 @@ module Gitlab def initialize(name, repository) @name = name @repository = repository - @path = File.join(repo_path.strip, 'hooks', name) + @path = File.join(repo_path, 'hooks', name) end def repo_path @@ -95,13 +95,13 @@ module Gitlab args = [ref, oldrev, newrev] stdout, stderr, status = Open3.capture3(env, path, *args, options) - [status.success?, Gitlab::Utils.nlbr(stderr.presence || stdout)] + [status.success?, stderr.presence || stdout] end def retrieve_error_message(stderr, stdout) err_message = stderr.read err_message = err_message.blank? ? stdout.read : err_message - Gitlab::Utils.nlbr(err_message) + err_message end end end |