route_soap 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/route_soap.rb +5 -5
- 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: b1ae1ee4967a992938908f8f06c0d2862f9ab97a41c26f0144e91bc3d28098c5
|
4
|
+
data.tar.gz: d5f299c1df1a45adf8d5f84bef2b4a95d0aa0a56a8a6093910651753d96dc755
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9f98f09651254d3235fd4a22f7d9011d43595cbf22ea6c2d173ca079421480bfd33cb514efc6816785f8fdf4b84a9724ec34492bc1656b2fd68615266c44d172
|
7
|
+
data.tar.gz: 416f324a14fcd08b85620dc711bc7356d564c05a52de07805d5a5c5021951abcfbba5284767c2fbc90312816645843f3d77657af57c1d07ecbb179b8383566c1
|
data/route_soap.rb
CHANGED
@@ -20,9 +20,9 @@ module RouteSoap
|
|
20
20
|
include Contracts
|
21
21
|
|
22
22
|
DEFAULT_BLACKLIST = [
|
23
|
-
|
24
|
-
|
25
|
-
|
23
|
+
/\/rails\/info/,
|
24
|
+
/\/rails\/info\/properties/,
|
25
|
+
/\/rails\/info\/routes/,
|
26
26
|
]
|
27
27
|
|
28
28
|
# Contract RouteLike => Route
|
@@ -76,7 +76,7 @@ module RouteSoap
|
|
76
76
|
|
77
77
|
Contract nil => Bool
|
78
78
|
def blacklisted?
|
79
|
-
@blacklist.
|
79
|
+
@blacklist.any? { |x| x.match?(path) }
|
80
80
|
end
|
81
81
|
|
82
82
|
Contract nil => Or[String, nil]
|
@@ -133,7 +133,7 @@ module RouteSoap
|
|
133
133
|
include Contracts
|
134
134
|
|
135
135
|
# Contract Or[RouterLike, nil] => Array[String]
|
136
|
-
def run(router
|
136
|
+
def run(router, blacklist)
|
137
137
|
Array.new.tap do |lines|
|
138
138
|
router.routes.each do |route|
|
139
139
|
Route.new(route, blacklist).tap do |simple_route|
|