From 7a901776dcff7cb866812ba5819db558f312e416 Mon Sep 17 00:00:00 2001 From: Joakim Antman Date: Tue, 25 Jul 2023 21:51:22 +0300 Subject: [PATCH] Make options compatible with Ruby 2.5 and 2.6 --- lib/jwt.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jwt.rb b/lib/jwt.rb index 75435472..2fba2450 100644 --- a/lib/jwt.rb +++ b/lib/jwt.rb @@ -54,7 +54,7 @@ def decode(jwt, key = nil, verify = true, options = {}, &keyfinder) # rubocop:di verify: verify, keyfinder: keyfinder, allowed_algorithms: normalizde_algorithm_option(options), - **configuration.decode.to_h.merge(options)).decode_segments + **configuration.decode.to_h.merge(options).transform_keys(&:to_sym)).decode_segments end # Order is very important - first check for string keys, next for symbols