registrar-rails 0.0.8.alpha → 0.0.9.alpha
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/registrar/rails/controller_extensions.rb +8 -0
- data/lib/registrar/rails/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: b6f8c6284bfffa18141cceac05c5a85a28faf176
|
4
|
+
data.tar.gz: dab9a8dd3d1c974a73929526dae0cecdeb9cbed4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fe496460276cfede00004d1d1dc0eb38d305b501a29fb4d25db2886f96886eb21433dbacfbdf0758c1fc4a584f409c67cfb3a751e9edaa62d8781f4545303d3b
|
7
|
+
data.tar.gz: 48960e40325c75911332d9f9c8864b6c63347ed82b0afc8aa150edbf0b75ba056bef61ef3baba4b2895336c406d9075654ab6b5e2fd4ef0e15f2ce708bf6f030
|
@@ -9,6 +9,7 @@ module Registrar
|
|
9
9
|
|
10
10
|
klass.class_eval do
|
11
11
|
helper_method :current_profile
|
12
|
+
helper_method :reload_current_profile
|
12
13
|
helper_method :current_profile?
|
13
14
|
helper_method :logout
|
14
15
|
end
|
@@ -32,6 +33,13 @@ module Registrar
|
|
32
33
|
session[CURRENT_PROFILE_KEY] = nil
|
33
34
|
end
|
34
35
|
|
36
|
+
def reload_current_profile
|
37
|
+
if env[REGISTRAR_PROFILE_KEY]
|
38
|
+
env[REGISTRAR_PROFILE_KEY] = Registrar::Middleware::config.handler.call(env[REGISTRAR_PROFILE_KEY])
|
39
|
+
try_to_store_current_profile
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
35
43
|
def current_profile
|
36
44
|
if session[CURRENT_PROFILE_KEY]
|
37
45
|
YAML.load session[CURRENT_PROFILE_KEY]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: registrar-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.9.alpha
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Owiesniak
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-05-
|
11
|
+
date: 2015-05-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|