governor 0.5.6 → 0.5.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ./
3
3
  specs:
4
- governor (0.5.6)
4
+ governor (0.5.7)
5
5
  rails (>= 3.0.5)
6
6
 
7
7
  GEM
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.6
1
+ 0.5.7
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{governor}
8
- s.version = "0.5.6"
8
+ s.version = "0.5.7"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Liam Morley"]
@@ -40,7 +40,8 @@ module Governor
40
40
  end
41
41
 
42
42
  def init_resource
43
- set_resource model_class.find(params["#{mapping.singular}_id"] || params[:id])
43
+ model_scope = the_governor.present? ? model_class.unscoped : model_class
44
+ set_resource model_scope.find(params["#{mapping.singular}_id"] || params[:id])
44
45
  end
45
46
 
46
47
  def the_governor
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ../..
3
3
  specs:
4
- governor (0.5.6)
4
+ governor (0.5.7)
5
5
  rails (>= 3.0.5)
6
6
 
7
7
  GEM
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: governor
3
3
  version: !ruby/object:Gem::Version
4
- hash: 7
4
+ hash: 5
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 5
9
- - 6
10
- version: 0.5.6
9
+ - 7
10
+ version: 0.5.7
11
11
  platform: ruby
12
12
  authors:
13
13
  - Liam Morley