Skip to content

Commit

Permalink
DE-1165 replace deprecated webhooks with new (#296)
Browse files Browse the repository at this point in the history
  • Loading branch information
mgrishko authored Sep 22, 2023
1 parent 8af4df3 commit aaec849
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ gem install mailgun-ruby
Gemfile:

```ruby
gem 'mailgun-ruby', '~>1.2.10'
gem 'mailgun-ruby', '~>1.2.11'
```

Usage
Expand Down Expand Up @@ -97,7 +97,7 @@ class UserMailer < ApplicationMailer
}
end
end
end
end
```

To get the Mailgun `message_id` after ActionMailer has successfully delivered the email:
Expand Down
2 changes: 1 addition & 1 deletion lib/mailgun/version.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# It's the version. Yeay!
module Mailgun
VERSION = '1.2.10'
VERSION = '1.2.11'
end
4 changes: 2 additions & 2 deletions lib/mailgun/webhooks/webhooks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def create(domain, action, url = '')
#
# Returns true or false
def create_all(domain, url = '')
%w(bounce click deliver drop open spam unsubscribe).each do |action|
%w(accepted clicked complained delivered opened permanent_fail temporary_fail unsubscribed).each do |action|
add_webhook domain, action, url
end
true
Expand Down Expand Up @@ -90,7 +90,7 @@ def remove(domain, action)
# Returns a Boolean on the success
def remove_all(domain)
fail Mailgun::ParameterError('Domain not provided to remove webhooks from') unless domain
%w(bounce click deliver drop open spam unsubscribe).each do |action|
%w(accepted clicked complained delivered opened permanent_fail temporary_fail unsubscribed).each do |action|
delete_webhook domain, action
end
end
Expand Down

0 comments on commit aaec849

Please sign in to comment.