lotus-controller 0.5.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/lotus/action/cookie_jar.rb +14 -0
- data/lib/lotus/controller/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0413b759d03b437e0efcce4f19779fdcf6ba5c61
|
4
|
+
data.tar.gz: bab88cc976ff852c27d82783861f179606cb705b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 38df22371c0f3ecbe875844e2fe5f17dc549b4c845c0f8f13d1b1d938a4aa2e078afd4f5fbb565d52aba22b7f6fb883af4c05b9d8f4dc8a17da1624c5954f4df
|
7
|
+
data.tar.gz: 4ef9119f03181b485771e80f8e37d0858e2c109c84bdfe5be9723032a739f54a63e2030a0a8e538682c7cbc715bf9278acbb9f01f989b33bec16bdc2c49640cb
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,10 @@
|
|
1
1
|
# Lotus::Controller
|
2
2
|
Complete, fast and testable actions for Rack
|
3
3
|
|
4
|
+
## v0.5.1 - 2016-01-19
|
5
|
+
### Fixed
|
6
|
+
- [Alfonso Uceda] Ensure `rack.session` cookie to not be sent twice when both `Lotus::Action::Cookies` and `Rack::Session::Cookie` are used together
|
7
|
+
|
4
8
|
## v0.5.0 - 2016-01-12
|
5
9
|
### Added
|
6
10
|
- [Luca Guidi] Reference a raised exception in Rack env's `rack.exception`. Compatibility with exception reporting SaaS.
|
@@ -16,6 +16,19 @@ module Lotus
|
|
16
16
|
# @api private
|
17
17
|
HTTP_HEADER = 'HTTP_COOKIE'.freeze
|
18
18
|
|
19
|
+
# The key used by Rack to set the session cookie
|
20
|
+
#
|
21
|
+
# We let CookieJar to NOT take care of this cookie, but it leaves the
|
22
|
+
# responsibility to the Rack middleware that handle sessions.
|
23
|
+
#
|
24
|
+
# This prevents <tt>Set-Cookie</tt> to be sent twice.
|
25
|
+
#
|
26
|
+
# @since 0.5.1
|
27
|
+
# @api private
|
28
|
+
#
|
29
|
+
# @see https://github.com/lotus/controller/issues/138
|
30
|
+
RACK_SESSION_KEY = :'rack.session'
|
31
|
+
|
19
32
|
# The key used by Rack to set the cookies as an Hash in the env
|
20
33
|
#
|
21
34
|
# @since 0.1.0
|
@@ -55,6 +68,7 @@ module Lotus
|
|
55
68
|
#
|
56
69
|
# @see Lotus::Action::Cookies#finish
|
57
70
|
def finish
|
71
|
+
@cookies.delete(RACK_SESSION_KEY)
|
58
72
|
@cookies.each { |k,v| v.nil? ? delete_cookie(k) : set_cookie(k, _merge_default_values(v)) }
|
59
73
|
end
|
60
74
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lotus-controller
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Luca Guidi
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-01-
|
13
|
+
date: 2016-01-19 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rack
|