mini_defender 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/mini_defender/rules/not_regex.rb +2 -2
- data/lib/mini_defender/rules/regex.rb +2 -2
- data/lib/mini_defender/version.rb +1 -1
- metadata +2 -3
- data/Gemfile.lock +0 -70
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: efdaf5cef8d3ef0e28e077f3d2caf7f7bf067c09a3f4e5d23db5af62f6b95b5a
|
|
4
|
+
data.tar.gz: caffb756c4fc342e22ce66fb7e71dd815ea1313cc69d3348c5726c7ac8bafcba
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d6e690f9c86463a6929aa097812001af721786df391bfe78d70680683ac046943c3d676a63b69be20883ea826542797a22edfa8144cfb3256b042f8dfcbe66c5
|
|
7
|
+
data.tar.gz: d9a09fd5c37e53a41cbd5c522fef92f487e3a7fb0a9e38fe2bb0d5d13c07aa08c7ae06a15d2182384f55609f6f623f0444851808142ad8c6a852b0f63102c24f
|
|
@@ -12,9 +12,9 @@ class MiniDefender::Rules::NotRegex < MiniDefender::Rule
|
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
def self.make(args)
|
|
15
|
-
raise ArgumentError, 'Expected a pattern as input.' unless args.length
|
|
15
|
+
raise ArgumentError, 'Expected a pattern as input.' unless args.length > 0
|
|
16
16
|
|
|
17
|
-
new(Regexp.compile(args
|
|
17
|
+
new(Regexp.compile(args.join(',')))
|
|
18
18
|
end
|
|
19
19
|
|
|
20
20
|
def passes?(attribute, value, validator)
|
|
@@ -12,9 +12,9 @@ class MiniDefender::Rules::Regex < MiniDefender::Rule
|
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
def self.make(args)
|
|
15
|
-
raise ArgumentError, 'Expected a pattern as input.' unless args.length
|
|
15
|
+
raise ArgumentError, 'Expected a pattern as input.' unless args.length > 0
|
|
16
16
|
|
|
17
|
-
new(Regexp.compile(args
|
|
17
|
+
new(Regexp.compile(args.join(',')))
|
|
18
18
|
end
|
|
19
19
|
|
|
20
20
|
def passes?(attribute, value, validator)
|
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.1.
|
|
4
|
+
version: 0.1.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ali Alhoshaiyan
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2022-11-
|
|
11
|
+
date: 2022-11-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|
|
@@ -76,7 +76,6 @@ extra_rdoc_files: []
|
|
|
76
76
|
files:
|
|
77
77
|
- CHANGELOG.md
|
|
78
78
|
- Gemfile
|
|
79
|
-
- Gemfile.lock
|
|
80
79
|
- LICENSE.md
|
|
81
80
|
- README.md
|
|
82
81
|
- RULES.md
|
data/Gemfile.lock
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: .
|
|
3
|
-
specs:
|
|
4
|
-
mini_defender (0.1.2)
|
|
5
|
-
actionpack (>= 6.0)
|
|
6
|
-
activemodel (>= 6.0)
|
|
7
|
-
activesupport (>= 6.0)
|
|
8
|
-
countries
|
|
9
|
-
|
|
10
|
-
GEM
|
|
11
|
-
remote: https://rubygems.org/
|
|
12
|
-
specs:
|
|
13
|
-
actionpack (7.0.4)
|
|
14
|
-
actionview (= 7.0.4)
|
|
15
|
-
activesupport (= 7.0.4)
|
|
16
|
-
rack (~> 2.0, >= 2.2.0)
|
|
17
|
-
rack-test (>= 0.6.3)
|
|
18
|
-
rails-dom-testing (~> 2.0)
|
|
19
|
-
rails-html-sanitizer (~> 1.0, >= 1.2.0)
|
|
20
|
-
actionview (7.0.4)
|
|
21
|
-
activesupport (= 7.0.4)
|
|
22
|
-
builder (~> 3.1)
|
|
23
|
-
erubi (~> 1.4)
|
|
24
|
-
rails-dom-testing (~> 2.0)
|
|
25
|
-
rails-html-sanitizer (~> 1.1, >= 1.2.0)
|
|
26
|
-
activemodel (7.0.4)
|
|
27
|
-
activesupport (= 7.0.4)
|
|
28
|
-
activesupport (7.0.4)
|
|
29
|
-
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
30
|
-
i18n (>= 1.6, < 2)
|
|
31
|
-
minitest (>= 5.1)
|
|
32
|
-
tzinfo (~> 2.0)
|
|
33
|
-
builder (3.2.4)
|
|
34
|
-
concurrent-ruby (1.1.10)
|
|
35
|
-
countries (5.2.0)
|
|
36
|
-
unaccent (~> 0.3)
|
|
37
|
-
crass (1.0.6)
|
|
38
|
-
erubi (1.11.0)
|
|
39
|
-
i18n (1.12.0)
|
|
40
|
-
concurrent-ruby (~> 1.0)
|
|
41
|
-
loofah (2.19.0)
|
|
42
|
-
crass (~> 1.0.2)
|
|
43
|
-
nokogiri (>= 1.5.9)
|
|
44
|
-
minitest (5.16.3)
|
|
45
|
-
nokogiri (1.13.9-arm64-darwin)
|
|
46
|
-
racc (~> 1.4)
|
|
47
|
-
racc (1.6.0)
|
|
48
|
-
rack (2.2.4)
|
|
49
|
-
rack-test (2.0.2)
|
|
50
|
-
rack (>= 1.3)
|
|
51
|
-
rails-dom-testing (2.0.3)
|
|
52
|
-
activesupport (>= 4.2.0)
|
|
53
|
-
nokogiri (>= 1.6)
|
|
54
|
-
rails-html-sanitizer (1.4.3)
|
|
55
|
-
loofah (~> 2.3)
|
|
56
|
-
rake (13.0.6)
|
|
57
|
-
tzinfo (2.0.5)
|
|
58
|
-
concurrent-ruby (~> 1.0)
|
|
59
|
-
unaccent (0.4.0)
|
|
60
|
-
|
|
61
|
-
PLATFORMS
|
|
62
|
-
arm64-darwin-21
|
|
63
|
-
|
|
64
|
-
DEPENDENCIES
|
|
65
|
-
mini_defender!
|
|
66
|
-
minitest (~> 5.0)
|
|
67
|
-
rake (~> 13.0)
|
|
68
|
-
|
|
69
|
-
BUNDLED WITH
|
|
70
|
-
2.3.20
|