Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Only include the legacy webhook payload keys for the original "push" …

…event
  • Loading branch information...
commit 43751957e9563f03694486f6fa32e9cc2bde88ed 1 parent 99d9bb0
@laserlemon laserlemon authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 app/jobs/notifier.rb
View
4 app/jobs/notifier.rb
@@ -2,7 +2,9 @@ class Notifier < Struct.new(:event, :url, :host_with_port, :rubygem, :version, :
def payload
rubygem_payload = rubygem.payload(version, host_with_port)
- rubygem_payload.merge("event" => event, "rubygem" => rubygem_payload).to_json
+ base = {"event" => event, "rubygem" => rubygem_payload}
+ payload = event == "push" ? rubygem_payload.merge(base) : base
+ payload.to_json
end
def authorization
Please sign in to comment.
Something went wrong with that request. Please try again.