merb-auth-slice-password 0.9.10 → 0.9.11
Sign up to get free protection for your applications and to get access to all the features.
- data/app/controllers/sessions.rb +13 -9
- metadata +5 -5
data/app/controllers/sessions.rb
CHANGED
@@ -1,9 +1,8 @@
|
|
1
1
|
class MerbAuthSlicePassword::Sessions < MerbAuthSlicePassword::Application
|
2
2
|
|
3
|
-
before :
|
4
|
-
after :_store_return_to_in_session # Need to hang onto the redirection during the session.abandon!
|
5
|
-
|
3
|
+
before :_maintain_auth_session_before, :exclude => [:destroy] # Need to hang onto the redirection during the session.abandon!
|
6
4
|
before :_abandon_session, :only => [:update, :destroy]
|
5
|
+
before :_maintain_auth_session_after, :exclude => [:destroy] # Need to hang onto the redirection during the session.abandon!
|
7
6
|
before :ensure_authenticated, :only => [:update]
|
8
7
|
|
9
8
|
# redirect from an after filter for max flexibility
|
@@ -33,15 +32,20 @@ class MerbAuthSlicePassword::Sessions < MerbAuthSlicePassword::Application
|
|
33
32
|
message[:notice] = "Logged Out"
|
34
33
|
redirect "/", :message => message
|
35
34
|
end
|
36
|
-
|
35
|
+
|
37
36
|
# @private
|
38
|
-
def
|
39
|
-
|
37
|
+
def _maintain_auth_session_before
|
38
|
+
@_maintain_auth_session = {}
|
39
|
+
Merb::Authentication.maintain_session_keys.each do |k|
|
40
|
+
@_maintain_auth_session[k] = session[k]
|
41
|
+
end
|
40
42
|
end
|
41
|
-
|
43
|
+
|
42
44
|
# @private
|
43
|
-
def
|
44
|
-
|
45
|
+
def _maintain_auth_session_after
|
46
|
+
@_maintain_auth_session.each do |k,v|
|
47
|
+
session[k] = v
|
48
|
+
end
|
45
49
|
end
|
46
50
|
|
47
51
|
# @private
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: merb-auth-slice-password
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Neighman
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-10-
|
12
|
+
date: 2008-10-29 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -20,7 +20,7 @@ dependencies:
|
|
20
20
|
requirements:
|
21
21
|
- - ">="
|
22
22
|
- !ruby/object:Gem::Version
|
23
|
-
version: 0.9.
|
23
|
+
version: 0.9.11
|
24
24
|
version:
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: merb-auth-core
|
@@ -30,7 +30,7 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.9.
|
33
|
+
version: 0.9.11
|
34
34
|
version:
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: merb-auth-more
|
@@ -40,7 +40,7 @@ dependencies:
|
|
40
40
|
requirements:
|
41
41
|
- - ">="
|
42
42
|
- !ruby/object:Gem::Version
|
43
|
-
version: 0.9.
|
43
|
+
version: 0.9.11
|
44
44
|
version:
|
45
45
|
description: Merb Slice that provides UI for password strategy of merb-auth.
|
46
46
|
email: has.sox@gmail.com
|