mini_defender 0.5.2 → 0.5.3

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: f7eb4878351ebf49bb42e33a10f8fefd34745b4067bdf40b50180792d2883819
4
- data.tar.gz: 93ec54964db744a7f2f03a7fc23bf96b6458637d94dbfb00c4307a0e5e598964
3
+ metadata.gz: 87731b96739bb1b69873c678f424ab5a9e5edf8ff2c084803582865fb6ce353b
4
+ data.tar.gz: 0e2c1516a69cfa689cccea7a2013bec0817ea9790831986fbe2fff79f51945c0
5
5
  SHA512:
6
- metadata.gz: a04dc7d2a819a0d3f8e443342900bd29db0c7e9b730128ff7d8f266f7853e52079166903997f660ef87c26c3965dd689c229bd5e533a0ff824debd3548f65417
7
- data.tar.gz: cd0109845a3f6f2ddc22c23448856124384554b6e3bbc75f1d952773c589797a421c1f7e04da15ed3461713f65ee436a8c102776ff0377dbbdeecc96da746196
6
+ metadata.gz: d5493f26115c5833ca54f55d4d551751fcd975b6a3c3c4ee8fe53b197f9c78c088d545d60751e026b22598549c3561593023b39b5cc17c8256d952e84f9b4ea1
7
+ data.tar.gz: ae08110a394548937b2ee193e583399e994f8cb82b6d828c5768d5ffb7cbfaaf663996ec0d9ad61d0d25c06de61d00dad06f1f722640800949dd5142cb1545ef
@@ -34,6 +34,10 @@ class MiniDefender::Rules::Hash < MiniDefender::Rule
34
34
  def passes?(attribute, value, validator)
35
35
  passes = value.is_a?(Hash)
36
36
 
37
+ unless passes
38
+ return false
39
+ end
40
+
37
41
  if @key_type == 'string'
38
42
  passes &= value.all? { |k, _| k.is_a?(String) }
39
43
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MiniDefender
4
- VERSION = "0.5.2"
4
+ VERSION = "0.5.3"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mini_defender
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ali Alhoshaiyan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-01-22 00:00:00.000000000 Z
11
+ date: 2024-01-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport