fe_core_ext 0.27.0 → 0.28.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fe_core_ext/core_ext/hash.rb +5 -0
- data/lib/fe_core_ext/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4c2bd081b4c23f5b77cadf7f367b306718ec447ce255b36c1784c2e7ad57664
|
4
|
+
data.tar.gz: 8f5c065793e9ab678ae277927ce3c7b43960c1e3d98154767b4c4278e370bcae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9547f388be92d324e5d7056e2d6ea80ba84899de21237602da1a6c7508dd74bab638e83dccfe653fc629669a9d4e27e0d4fdd3ad98abc1fd3a6e4392f825bca5
|
7
|
+
data.tar.gz: 72e843ceec85b37a0d85f4f6ed58faf9d534914e56fa5e1fbafd343399ee72e192683a8c4e52495e545d7e9b656a9d650588d79807efed02425d0c1d9acdf4a2
|
@@ -10,6 +10,11 @@ module FeCoreExt::CoreExt::Hash
|
|
10
10
|
def snake_symbolize_keys
|
11
11
|
transform_keys { |key| key.to_s.snakecase.to_sym }
|
12
12
|
end
|
13
|
+
|
14
|
+
def rename_key(original_key, new_key)
|
15
|
+
self[new_key] = delete(original_key) if key?(original_key)
|
16
|
+
self
|
17
|
+
end
|
13
18
|
end
|
14
19
|
|
15
20
|
class Hash
|
data/lib/fe_core_ext/version.rb
CHANGED