cancan-export 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ab8f4923b92deaad80e7e97bc00cc52b61c4cf23
4
- data.tar.gz: b8348cc0d0f60d391644fcbec7a903dea69fd257
3
+ metadata.gz: 10a93cff61fd331d14f87f89c16b60b81aa3979e
4
+ data.tar.gz: 5d1b0c6a9c4b7bc5c455e7dd3b7cce9a1d19c177
5
5
  SHA512:
6
- metadata.gz: a819e03e5f4abf8633706c04e655f06271695116a91efad3855a52d03303358c388e6ec0ce9b672b0d6d73e6c80bc94f0e48da8775cbf4e1631f2809027f8f85
7
- data.tar.gz: 5196e4031a3cbd80c5a7e88e8617c4c0d6a3b2138be478049185d7f85764e6cc7b8c186e0c8da11327550f090c3ceb4c15782fc51e68a80df3e05c1f792cb770
6
+ metadata.gz: 198421aaca5506effa3956495c162eccbff2f4afd64e8d10c0c6b70ba27ad6dc15191f9ba2cd77f76cae074515cd09ed0db848ba22d4149f44b6bb49d68d1977
7
+ data.tar.gz: 1f68e1af4f9dbf981833d8bbba394b9137358b797c2ef6b7c11156ba0406f5268db113e9341eeedcbed47145a652e4674f49fd1b0f4998941dbbd1b038bb3c63
@@ -7,7 +7,7 @@ module CanCan
7
7
  matchAll: @match_all,
8
8
  baseBehavior: @base_behavior,
9
9
  subjects: @subjects.map(&:to_s),
10
- actions: ability.send(:expand_actions, @actions).map(&:to_s),
10
+ actions: ability.send(:expand_actions, @actions).map(&:to_s).uniq,
11
11
  conditions: @conditions,
12
12
  blockSource: @block && compiler.to_js(@block)
13
13
  }
@@ -6,7 +6,7 @@ module CanCan
6
6
  super.tap do |g|
7
7
  if current_user
8
8
  g.user ||= current_user
9
- g.ability ||= ::Ability.new(g.user)
9
+ g.ability ||= current_ability
10
10
  end
11
11
  end
12
12
  end
@@ -1,5 +1,5 @@
1
1
  module CanCan
2
2
  module Export
3
- VERSION = "0.2.1"
3
+ VERSION = "0.2.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cancan-export
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergey Baev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-11-21 00:00:00.000000000 Z
11
+ date: 2015-12-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -106,7 +106,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
106
106
  version: '0'
107
107
  requirements: []
108
108
  rubyforge_project:
109
- rubygems_version: 2.4.8
109
+ rubygems_version: 2.2.2
110
110
  signing_key:
111
111
  specification_version: 4
112
112
  summary: Exports CanCan rules to the client-side.