repositor 0.7.2 → 0.7.3

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: af297e7c3e066d3e865ceb83c2b1086fb5e04494
4
- data.tar.gz: bacf7f17f2ef25a76e6791aaf86c015c199c555f
3
+ metadata.gz: 7f9c1108e2bdec1ae51f438910da16941d2b83e7
4
+ data.tar.gz: 8e32532a6cb587b1892c0bb88b3907de1b1ea74a
5
5
  SHA512:
6
- metadata.gz: 8a260827f8d71f4b85313cd754256b12907441f747ff3c915e46829ece3159ed2640375a9b1b3b737a3040fcab06d304ffa040460a6a4ac898c42a2ada384f3f
7
- data.tar.gz: 9275022dafed019e74b93215dd8bf8dd083fe8d9d9a69c63b52cdc73bd7818ba0df4e4d89979e6b03cb999b062d36a93e6d96faa10bac13a25f2a58096a9c5b1
6
+ metadata.gz: 651aa3e9546ab6be9f3869a8ac649582c794c4571a7c1eb3815c34c8aa7028d9a5b3fe6ecc55c15dcd186933efcab6698260b3c177973be8aab75881c6026feb
7
+ data.tar.gz: 46651337361ec0a03192d87fa122c7fb2ded620e0b98d5d1c8758b2757a8357c44e68862134d4aabd02b2da695aa2d34c8047f413804a32b0cc8788bd5fc68f6
@@ -1,6 +1,4 @@
1
1
  require 'repositor/active_record'
2
- require 'active_support/inflector'
3
- require 'active_support/core_ext/module/delegation'
4
2
 
5
3
  module Repositor
6
4
  end
@@ -1,3 +1,6 @@
1
+ require 'active_support/core_ext/module/delegation'
2
+ require 'active_support/inflector'
3
+
1
4
  module Repositor
2
5
  module ActiveRecord
3
6
  attr_reader :model
@@ -14,7 +17,7 @@ module Repositor
14
17
 
15
18
  def find_or_initialize(id, friendly: false)
16
19
  friendly ? friendly_find(id) : model.find(id)
17
- rescue ActiveRecord::RecordNotFound
20
+ rescue ::ActiveRecord::RecordNotFound
18
21
  model.new
19
22
  end
20
23
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: repositor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.2
4
+ version: 0.7.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Volodya Sveredyuk