From 99053773048f8ac51a1f9d4138fb66dc48eb3496 Mon Sep 17 00:00:00 2001 From: Kirill Borzov Date: Fri, 22 Aug 2014 13:45:38 +0300 Subject: [PATCH] Issue: initial parameter for hipchat. --- app/models/project_services/hipchat_service.rb | 2 +- app/services/merge_requests/create_service.rb | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/models/project_services/hipchat_service.rb b/app/models/project_services/hipchat_service.rb index 094058c..e825b32 100644 --- a/app/models/project_services/hipchat_service.rb +++ b/app/models/project_services/hipchat_service.rb @@ -39,7 +39,7 @@ def fields ] end - def execute(push_data, type) + def execute(push_data, type = 'push') if type == 'merge' gate[room].send('GitLab', create_merge_message(push_data)) else diff --git a/app/services/merge_requests/create_service.rb b/app/services/merge_requests/create_service.rb index d1bf827..462fbbf 100644 --- a/app/services/merge_requests/create_service.rb +++ b/app/services/merge_requests/create_service.rb @@ -10,7 +10,9 @@ def execute event_service.open_mr(merge_request, current_user) notification_service.new_merge_request(merge_request, current_user) merge_request.create_cross_references!(merge_request.project, current_user) + # @oresh Merge request created hook. execute_hooks(merge_request) + execute_services(merge_request) end merge_request