diff --git a/CHANGELOG b/CHANGELOG index 550819880718da0bd3f8b540c9266b3817f4872b..fa8ecbd8c74be7bb460a022d333b522e464a9309 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -11,6 +11,7 @@ v 7.11.0 (unreleased) - - - Improve new project command options (Ben Bodenmiller) + - Prevent sending empty messages to HipChat (Chulki Lee) v 7.10.0 (unreleased) - Ignore submodules that are defined in .gitmodules but are checked in as directories. diff --git a/app/models/project_services/hipchat_service.rb b/app/models/project_services/hipchat_service.rb index d264a56ebdf496582c6861139b1eb8a789195a1f..07520eab5d13164793824b186ecb693adb4314cd 100644 --- a/app/models/project_services/hipchat_service.rb +++ b/app/models/project_services/hipchat_service.rb @@ -50,8 +50,9 @@ class HipchatService < Service def execute(data) return unless supported_events.include?(data[:object_kind]) - - gate[room].send('GitLab', create_message(data)) + message = create_message(data) + return unless message.present? + gate[room].send('GitLab', message) end private