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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/route_soap.rb +5 -5
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1414f90d33479f31fd162c025d52ee61c8ed980b7cd6d5454842531aae17376b
4
- data.tar.gz: 84f21b6e05e13a1ec95a512e9b92a0995c97184dc5a83974f96fff40fb69cc0b
3
+ metadata.gz: b1ae1ee4967a992938908f8f06c0d2862f9ab97a41c26f0144e91bc3d28098c5
4
+ data.tar.gz: d5f299c1df1a45adf8d5f84bef2b4a95d0aa0a56a8a6093910651753d96dc755
5
5
  SHA512:
6
- metadata.gz: ad3ece2cfe0b1d2169f0614e3d81f6b89eafe6f5b88e08da5bda944864d778915717b58d37a0cc39f925f56f5aa1fa0b736eb150eb655156660c5ab2843ab6ab
7
- data.tar.gz: c74769e5cd579f50d3f0a8c9bbf2504b47bb26b7a06584f647833e6c170b6eb04a3d3c644b4f9cd20c079d05974ff1e1b0a332b7dc459a0630d7229a5405674b
6
+ metadata.gz: 9f98f09651254d3235fd4a22f7d9011d43595cbf22ea6c2d173ca079421480bfd33cb514efc6816785f8fdf4b84a9724ec34492bc1656b2fd68615266c44d172
7
+ data.tar.gz: 416f324a14fcd08b85620dc711bc7356d564c05a52de07805d5a5c5021951abcfbba5284767c2fbc90312816645843f3d77657af57c1d07ecbb179b8383566c1
@@ -20,9 +20,9 @@ module RouteSoap
20
20
  include Contracts
21
21
 
22
22
  DEFAULT_BLACKLIST = [
23
- "/rails/info",
24
- "/rails/info/properties",
25
- "/rails/info/routes"
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.include?(path)
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 = DefaultRouter, blacklist = [])
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|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: route_soap
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philip Cunningham