tzispa_helpers 0.1.14 → 0.1.15
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/CHANGELOG.md +4 -1
- data/lib/tzispa/helpers/response.rb +8 -0
- data/lib/tzispa/helpers/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5c8aff935e68aee6677326a6cdb4c043b19053cd
|
|
4
|
+
data.tar.gz: c3aac1290c4774b083634e2db41a01c3623d6484
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f267265f435203f642a10a9c33e4c4b2e27f42dc59ad2fa1511853103c8a5d47d8036be744ea3736449d57fd2779c5214f7b3c6e328dd04125934ccf4e2788e5
|
|
7
|
+
data.tar.gz: 421dbdd72cc19ef032f4bf3a2594f9b451bdc49f3915c9152fe3054b3abea33c44b2bc10c5695dfdff14944dfa4cc1035b5efb4a99721b91cb9c043df5004477
|
data/CHANGELOG.md
CHANGED
|
@@ -54,6 +54,14 @@ module Tzispa
|
|
|
54
54
|
halt(*args)
|
|
55
55
|
end
|
|
56
56
|
|
|
57
|
+
# Halt processing and permanet_redirect redirect to the URI provided.
|
|
58
|
+
def permanent_redirect(uri, absolute, *args)
|
|
59
|
+
status 301
|
|
60
|
+
response['Location'] = uri(uri.to_s, absolute)
|
|
61
|
+
halt(*args)
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
|
|
57
65
|
# Generates the absolute URI for a given path in the app.
|
|
58
66
|
# Takes Rack routers and reverse proxies into account.
|
|
59
67
|
def uri(addr = nil, absolute = true)
|