dry_controller 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,5 @@
1
+ require 'dry_controller/errors/resource_not_found'
2
+
1
3
  module DryController
2
4
  extend ActiveSupport::Concern
3
5
 
@@ -44,7 +46,7 @@ module DryController
44
46
 
45
47
  unless obj = instance_variable_get("@#{resource_name}")
46
48
  obj ||= if params[:id].present?
47
- resource_class.where(id: params[:id]).first
49
+ resource_class.find(params[:id])
48
50
  else
49
51
  resource_class.new(params[resource_name])
50
52
  end
@@ -1,3 +1,3 @@
1
1
  module DryController
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dry_controller
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: