Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-02-25 16:05:45 +0300
committerDouwe Maan <douwe@gitlab.com>2015-02-25 16:20:35 +0300
commite0c186c35735a2dc9e05e88ad9975ae016c815d9 (patch)
treec040a133925106da34de651cb88e155988a079fc /app/workers
parent0e7d1fd44f057c83c5384618f4599271f9fdd006 (diff)
Add option to send EmailsOnPush from committer email if domain matches.
See #1809.
Diffstat (limited to 'app/workers')
-rw-r--r--app/workers/emails_on_push_worker.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/workers/emails_on_push_worker.rb b/app/workers/emails_on_push_worker.rb
index e3f6f3a6aef..3814b17a8a2 100644
--- a/app/workers/emails_on_push_worker.rb
+++ b/app/workers/emails_on_push_worker.rb
@@ -1,7 +1,7 @@
class EmailsOnPushWorker
include Sidekiq::Worker
- def perform(project_id, recipients, push_data)
+ def perform(project_id, recipients, push_data, send_from_committer_email = false)
project = Project.find(project_id)
before_sha = push_data["before"]
after_sha = push_data["after"]
@@ -19,7 +19,7 @@ class EmailsOnPushWorker
return false unless compare && compare.commits.present?
recipients.split(" ").each do |recipient|
- Notify.repository_push_email(project_id, recipient, author_id, branch, compare).deliver
+ Notify.repository_push_email(project_id, recipient, author_id, branch, compare, send_from_committer_email).deliver
end
ensure
compare = nil