switch_user 1.0.1 → 1.0.2
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/switch_user/data_source.rb +4 -1
- data/lib/switch_user/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: 298959f7be5e189d86db97729a7684e08029e57e
|
4
|
+
data.tar.gz: 3ce27c56ef2e8b666dcf62461d57f44134e82dc2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f177c7d22660c949bef98580a6c14d1f3d00ed478435b60850c7c362fbe8e7653dd17757bbe187e472326cba9ab4ff09bc0f8be87dd1cbf037455e1bb342927
|
7
|
+
data.tar.gz: 4f3a5af7f73f55fc84c706aa7b6fb1ff592a9e35773d943c5b630e784599524dcda6a7bad608182d3d20ff29006afccbddddb0dcf53f6cb8605b2193c036510b
|
data/CHANGELOG.md
CHANGED
@@ -30,7 +30,10 @@ module SwitchUser
|
|
30
30
|
end
|
31
31
|
|
32
32
|
def find_scope_id(scope_id)
|
33
|
-
|
33
|
+
scope_regexp = /\A#{scope}_/
|
34
|
+
return unless scope_id =~ scope_regexp
|
35
|
+
|
36
|
+
user = loader.call.find_by identifier => scope_id.sub(scope_regexp, '')
|
34
37
|
Record.new(user, self)
|
35
38
|
end
|
36
39
|
end
|
data/lib/switch_user/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: switch_user
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Huang
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-06-
|
12
|
+
date: 2015-06-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|