webauthn 3.2.1 → 3.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4531338c1a9301a58aea6f70458311891a81c06f50e2c223eb812ec24e980e2c
4
- data.tar.gz: fae69f115e3f93a942446d30115e0268b0a73bd13a9a565b4235ed5103ab7b98
3
+ metadata.gz: 410e18172c68e2171f46e15d7b34cd56ef7859c4efd421b6a84a3469f0281c41
4
+ data.tar.gz: 16841587928fb284c5ad542868a0d6a21f6152a82bdd76abc0ae537887275bc3
5
5
  SHA512:
6
- metadata.gz: '038380bb699e7e9d8ee728b256ae2de062bebed3b9531174c5d428e210bcb6896ba4907ea17343239193900d7d1ffc97bde73e99323e12b8377887f7ba0dcd9a'
7
- data.tar.gz: eb7062a1dde7a0099154580075bf060a32bdcf000c8156c77048829e38e89e227e0f3d5a15f2d80ba9c408733f94c399bb96f8d19a184bad36943f8309ce3d4a
6
+ metadata.gz: b7337230a3b9118e55bfd1ac84858d163bc173d70107e5f425077579801c5d1b68cf6ec0be65d0317c63d69d1594d7a50662a42e3ed4ac34e45cae97954a8477
7
+ data.tar.gz: 53dcf09f8065ee447633de769c5d4587e39150f117fa3f6226a78fbbac7b48be9195bcd40ff14a683f06343a2f10f46c3df057dedaf96fcabfedb41865b64362
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## [v3.2.2] - 2024-11-14
4
+
5
+ ### Fixed
6
+
7
+ - Fix `PublicKeyCredential::Options#.as_json` not camelCase'ing keys of attributes with hash or arrays as values. [#445](https://github.com/cedarcode/webauthn-ruby/pull/445) [@santiagorodriguez96]
8
+
3
9
  ## [v3.2.1] - 2024-11-14
4
10
 
5
11
  ### Fixed
@@ -4,19 +4,21 @@ module WebAuthn
4
4
  module JSONSerializer
5
5
  # Argument wildcard for Ruby on Rails controller automatic object JSON serialization
6
6
  def as_json(*)
7
- to_hash_with_camelized_keys
7
+ deep_camelize_keys(to_hash)
8
8
  end
9
9
 
10
10
  private
11
11
 
12
- def to_hash_with_camelized_keys
12
+ def to_hash
13
13
  attributes.each_with_object({}) do |attribute_name, hash|
14
14
  value = send(attribute_name)
15
15
 
16
- if value && value.respond_to?(:as_json)
17
- hash[camelize(attribute_name)] = value.as_json
18
- elsif value
19
- hash[camelize(attribute_name)] = deep_camelize_keys(value)
16
+ if value.respond_to?(:as_json)
17
+ value = value.as_json
18
+ end
19
+
20
+ if value
21
+ hash[attribute_name] = value
20
22
  end
21
23
  end
22
24
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module WebAuthn
4
- VERSION = "3.2.1"
4
+ VERSION = "3.2.2"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webauthn
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.1
4
+ version: 3.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gonzalo Rodriguez