From 438e93f7fda46f6a4b1f143337b720ef601d7bf5 Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Sat, 7 Sep 2019 02:58:54 +0900 Subject: [PATCH] Passing in a Hash instance as kwargs parameters requires the "double splat" prefix --- actioncable/lib/action_cable/connection/test_case.rb | 2 +- activejob/lib/active_job/exceptions.rb | 2 +- .../connection_adapters/postgresql/oid/specialized_string.rb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/actioncable/lib/action_cable/connection/test_case.rb b/actioncable/lib/action_cable/connection/test_case.rb index f1673fea08..dcae455f65 100644 --- a/actioncable/lib/action_cable/connection/test_case.rb +++ b/actioncable/lib/action_cable/connection/test_case.rb @@ -185,7 +185,7 @@ def connect(path = ActionCable.server.config.mount_path, **request_params) connection = self.class.connection_class.allocate connection.singleton_class.include(TestConnection) - connection.send(:initialize, build_test_request(path, request_params)) + connection.send(:initialize, build_test_request(path, **request_params)) connection.connect if connection.respond_to?(:connect) # Only set instance variable if connected successfully diff --git a/activejob/lib/active_job/exceptions.rb b/activejob/lib/active_job/exceptions.rb index 8e83246303..b7747d4953 100644 --- a/activejob/lib/active_job/exceptions.rb +++ b/activejob/lib/active_job/exceptions.rb @@ -115,7 +115,7 @@ def discard_on(*exceptions) # end # end def retry_job(options = {}) - instrument :enqueue_retry, options.slice(:error, :wait) do + instrument :enqueue_retry, **options.slice(:error, :wait) do enqueue options end end diff --git a/activerecord/lib/active_record/connection_adapters/postgresql/oid/specialized_string.rb b/activerecord/lib/active_record/connection_adapters/postgresql/oid/specialized_string.rb index 4ad1344f05..80316b35fe 100644 --- a/activerecord/lib/active_record/connection_adapters/postgresql/oid/specialized_string.rb +++ b/activerecord/lib/active_record/connection_adapters/postgresql/oid/specialized_string.rb @@ -9,7 +9,7 @@ class SpecializedString < Type::String # :nodoc: def initialize(type, **options) @type = type - super(options) + super(**options) end end end