switch_user 1.0.0 → 1.0.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 +8 -121
- data/lib/switch_user/data_source.rb +2 -2
- data/lib/switch_user/version.rb +1 -1
- data/spec/switch_user/data_source_spec.rb +3 -3
- 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: 0a2285650a543855f3577a01117f8bb95b21f269
|
4
|
+
data.tar.gz: f0237e0ae73041323af735d1102040dd032e733f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 485187b3600504bd288a4419682b8486168bb3762f7c1b388076a95f32a90d93eb6fae04ce159e2f137690a1e370634c56f82263f212570284cd7b6d2f87e002
|
7
|
+
data.tar.gz: e09079278f05c4e54a071305a1363b404f067dbcfe689a00d99f037bf7bccb63c2863d25cb5a169e4629e48e5eb04c36a89d6f897d796ce6d1338bdaa18fb56b
|
data/CHANGELOG.md
CHANGED
@@ -1,126 +1,13 @@
|
|
1
1
|
# Next Release
|
2
2
|
|
3
|
-
##
|
3
|
+
## 1.0.1
|
4
4
|
|
5
|
-
*
|
5
|
+
* Fix typo in `GuestDataSource`
|
6
|
+
* Allow custom method as `available_users_names`
|
6
7
|
|
7
|
-
##
|
8
|
+
## 1.0.0 (06/22/2015)
|
8
9
|
|
9
|
-
*
|
10
|
-
*
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
* Fix false positive with `belongs_to` -> `belongs_to` for active\_record 4.2
|
15
|
-
* Activate active\_record hacks only when Bullet already start
|
16
|
-
|
17
|
-
## 4.14.5
|
18
|
-
|
19
|
-
* Don't execute query when running `to_sql`
|
20
|
-
* Send backtrace to `uniform_notifier`
|
21
|
-
* Fix sse response check
|
22
|
-
* Dynamically delegate available notifiers to UniformNotifier
|
23
|
-
|
24
|
-
## 4.14.4
|
25
|
-
|
26
|
-
* Fix false N + 1 warnings on Rails 4.2
|
27
|
-
|
28
|
-
## 4.14.3
|
29
|
-
|
30
|
-
* Fix false positive on create
|
31
|
-
|
32
|
-
## 4.14.2
|
33
|
-
|
34
|
-
* Hotfix nil object when `add_impossible_object`
|
35
|
-
|
36
|
-
## 4.14.1
|
37
|
-
|
38
|
-
* Fix `has_one` then `has_many` associations in rails 4.2
|
39
|
-
* Append js and dom to html body in proper position
|
40
|
-
|
41
|
-
## 4.14.0 (10/03/2014)
|
42
|
-
|
43
|
-
* Support rails 4.2
|
44
|
-
* Polish notification output
|
45
|
-
* Fix warning: `*' interpreted as argument prefix
|
46
|
-
|
47
|
-
## 4.13.0 (07/19/2014)
|
48
|
-
|
49
|
-
* Support include? call on ar associations
|
50
|
-
|
51
|
-
## 4.12.0 (07/13/2014)
|
52
|
-
|
53
|
-
* Fix false n+1 queries caused by inversed objects.
|
54
|
-
* Replace .id with .primary_key_value
|
55
|
-
* Rename bullet_ar_key to bullet_key
|
56
|
-
* Fix rails sse detect
|
57
|
-
* Fix bullet using in test environment
|
58
|
-
* Memoize whoami
|
59
|
-
|
60
|
-
## 4.11.0 (06/24/2014)
|
61
|
-
|
62
|
-
* Support empty? call on ar associations
|
63
|
-
* Skip detecting if object is a new record
|
64
|
-
|
65
|
-
## 4.10.0 (06/06/2014)
|
66
|
-
|
67
|
-
* Handle join query smarter
|
68
|
-
* Support mongoid 4.0
|
69
|
-
* Thread safe
|
70
|
-
* Add debug mode
|
71
|
-
|
72
|
-
## 4.9.0 (04/30/2014)
|
73
|
-
|
74
|
-
* Add Bullet.stacktrace_includes option
|
75
|
-
* Applied keyword argument fixes on Ruby 2.2.0
|
76
|
-
* Add bugsnag notifier
|
77
|
-
* Support rails 4.1.0
|
78
|
-
|
79
|
-
## 4.8.0 (02/16/2014)
|
80
|
-
|
81
|
-
* Support rails 4.1.0.beta1
|
82
|
-
* Update specs to be RSpec 3.0 compatible
|
83
|
-
* Update latest minor version activerecord and mongoid on travis
|
84
|
-
|
85
|
-
## 4.7.0 (11/03/2013)
|
86
|
-
|
87
|
-
* Add coverall support
|
88
|
-
* Add helper to profile code outside a request
|
89
|
-
* Add activesupport dependency
|
90
|
-
* Add Bullet.raise notification
|
91
|
-
* Add Bullet.add_footer notification
|
92
|
-
* Fix activerecord4 warnings in test code
|
93
|
-
|
94
|
-
## 4.6.0 (04/18/2013)
|
95
|
-
|
96
|
-
* Fix Bullet::Rack to support sinatra
|
97
|
-
|
98
|
-
## 4.5.0 (03/24/2013)
|
99
|
-
|
100
|
-
* Add api way to access captured associatioin
|
101
|
-
* Allow disable n_plus_one_query, unused_eager_loading and counter_cache respectively
|
102
|
-
* Add whitelist
|
103
|
-
|
104
|
-
## 4.4.0 (03/15/2013)
|
105
|
-
|
106
|
-
* Remove disable_browser_cache option
|
107
|
-
* Compatible with Rails 4.0.0.beta1
|
108
|
-
|
109
|
-
## 4.3.0 (12/28/2012)
|
110
|
-
|
111
|
-
* Fix content-length for non ascii html
|
112
|
-
* Add mongoid 2.5.x support
|
113
|
-
|
114
|
-
## 4.2.0 (09/29/2012)
|
115
|
-
|
116
|
-
* Add Bullet::Dependency to check AR and mongoid version
|
117
|
-
* Add Rails 4 support
|
118
|
-
* Add airbrake notifier support
|
119
|
-
|
120
|
-
## 4.1.0 (05/30/2012)
|
121
|
-
|
122
|
-
* Add mongoid 3 support
|
123
|
-
|
124
|
-
## 4.0.0 (05/09/2012)
|
125
|
-
|
126
|
-
* Add mongoid support
|
10
|
+
* Performance improved, only load necessary data.
|
11
|
+
* Devise provider- don't store `sign_in` details
|
12
|
+
* Security :guardsman:, raise RoutingError in `developer_modes_only`
|
13
|
+
* Restore original user after sorcery logout
|
@@ -26,7 +26,7 @@ module SwitchUser
|
|
26
26
|
end
|
27
27
|
|
28
28
|
def all
|
29
|
-
loader.call.
|
29
|
+
loader.call.map { |user| Record.new(user, self) }
|
30
30
|
end
|
31
31
|
|
32
32
|
def find_scope_id(scope_id)
|
@@ -36,7 +36,7 @@ module SwitchUser
|
|
36
36
|
end
|
37
37
|
|
38
38
|
class GuestDataSource
|
39
|
-
def
|
39
|
+
def all
|
40
40
|
[ GuestRecord.new ]
|
41
41
|
end
|
42
42
|
|
data/lib/switch_user/version.rb
CHANGED
@@ -31,10 +31,10 @@ module SwitchUser
|
|
31
31
|
RSpec.describe GuestDataSource do
|
32
32
|
let(:source) { GuestDataSource.new }
|
33
33
|
|
34
|
-
describe '#
|
34
|
+
describe '#all' do
|
35
35
|
it 'gets a GuestRecord' do
|
36
|
-
expect(source.
|
37
|
-
expect(source.
|
36
|
+
expect(source.all.size).to eq 1
|
37
|
+
expect(source.all.first).to be_instance_of GuestRecord
|
38
38
|
end
|
39
39
|
end
|
40
40
|
|
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.1
|
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-26 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|