redirect-rails 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/redirect/middleware.rb +1 -1
- data/lib/redirect/rails/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: fd0f45248f4da1f4c59d5738a560c46911d19475734ed4f813afcc5489eb7f1c
|
4
|
+
data.tar.gz: 3468f49a9e12108d13c458990ad5073ef9b1ff52d7b5854b23af1191d5838862
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 034ad9b08df9ccf6648f718dc77b53dfeeb3272447a883a30c88b42a88888e2a84febb737360e8d642eb6921771c3d8d600b9a93b2f38a36d28fac5b1f784f84
|
7
|
+
data.tar.gz: c5997266f646d25d1e9900a446911faf0d85616b22c6870a5710956f1d440ff3add16ff053afb50da81a61e53ff4b4b96a5130a868cdb08ed3721c24e0f75a0a
|
data/lib/redirect/middleware.rb
CHANGED
@@ -29,7 +29,7 @@ module Redirect
|
|
29
29
|
return unless Redirect::Rails.hosts
|
30
30
|
|
31
31
|
Redirect::Rails.hosts.map do |host, redirect_url|
|
32
|
-
return ERB.new(redirect_url).result(binding) if Regexp.new(host).match(
|
32
|
+
return ERB.new(redirect_url).result(binding) if Regexp.new(host).match(request_host)
|
33
33
|
end.first
|
34
34
|
end
|
35
35
|
|