From 3adb2619857fabdbd40de8fd4199f3b7ffdaed36 Mon Sep 17 00:00:00 2001 From: bogdanvlviv Date: Thu, 27 Dec 2018 00:19:51 +0200 Subject: Fix Ruby warnings in actionmailbox ``` rails/actionmailbox$ bundle exec rake tests (snip) ... rails/activerecord/lib/active_record/persistence.rb:48: warning: in `create!': the last argument was passed as a single Hash rails/actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb:21: warning: although a splat keyword arguments here ... (snip) ``` --- actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'actionmailbox') diff --git a/actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb b/actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb index 244a2e439b..2ad4525929 100644 --- a/actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb +++ b/actionmailbox/app/models/action_mailbox/inbound_email/message_id.rb @@ -18,7 +18,7 @@ module ActionMailbox::InboundEmail::MessageId # attachment called `raw_email`. Before the upload, extract the Message-ID from the `source` and set # it as an attribute on the new `InboundEmail`. def create_and_extract_message_id!(source, **options) - create! message_id: extract_message_id(source), **options do |inbound_email| + create! options.merge(message_id: extract_message_id(source)) do |inbound_email| inbound_email.raw_email.attach io: StringIO.new(source), filename: "message.eml", content_type: "message/rfc822" end end -- cgit v1.2.3