light-decorator 0.5.2 → 0.5.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: 1b2cc38013100334f2c45e436c169ebbb85fdb9e
4
- data.tar.gz: 2bf2245562ac16976d6e0d3c375fc7eba8124f9e
3
+ metadata.gz: 78faf0429db08cdbb372146394c776d42228e916
4
+ data.tar.gz: bb207231bd193d44de3f2bd97cbaf0d836653b97
5
5
  SHA512:
6
- metadata.gz: 4e51d3e2e781813f986e62b768ed93eb0988e24217cf455af5eefe90288732dce0083faa05277de1e0906a35d25a14bfaf2a2e244d28603d3c8e22551ad9a557
7
- data.tar.gz: cbed29f31d8ad962ed1c5c76e240f25b6cfadc7a3b648c1487f1a716672f1e92c4957f9ed57664a6c17c049ba7956b161db45697f3ec275b92288660eca66023
6
+ metadata.gz: 6fec0dc9c556822ae7b628bf1f52a1209eb4843a4f753ee2a0df51e0398e783e19f434039b0dc7cfb118b283ccbd9534bbeacc2382cb82afb5e3e6848ef68e32
7
+ data.tar.gz: 23b3b5ebc2c79756f9b2f0b48720a04119a92631e6e363c88fbd48c470ce83d4cb2ef241875c802c1fd843f4cabc63e81f3175c469c521a42b7ad4886c0888d1
data/README.md CHANGED
@@ -15,7 +15,7 @@ Decorator pattern - What is it?
15
15
  Add this line to your application's Gemfile:
16
16
 
17
17
  ```ruby
18
- gem 'light-decorator', '~> 0.5.2'
18
+ gem 'light-decorator', '~> 0.5.3'
19
19
  ```
20
20
 
21
21
  ## Usage
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ../
3
3
  specs:
4
- light-decorator (0.5.1)
4
+ light-decorator (0.5.3)
5
5
  rails (>= 4.0.0)
6
6
  request_store (>= 1.0.0)
7
7
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ../
3
3
  specs:
4
- light-decorator (0.5.1)
4
+ light-decorator (0.5.3)
5
5
  rails (>= 4.0.0)
6
6
  request_store (>= 1.0.0)
7
7
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ../
3
3
  specs:
4
- light-decorator (0.5.1)
4
+ light-decorator (0.5.3)
5
5
  rails (>= 4.0.0)
6
6
  request_store (>= 1.0.0)
7
7
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ../
3
3
  specs:
4
- light-decorator (0.5.1)
4
+ light-decorator (0.5.3)
5
5
  rails (>= 4.0.0)
6
6
  request_store (>= 1.0.0)
7
7
 
@@ -62,7 +62,8 @@ module Light
62
62
  def decorate_associations
63
63
  object.class.reflect_on_all_associations.map(&:name).each do |reflection_name|
64
64
  define_singleton_method reflection_name do
65
- object.public_send(reflection_name).decorate(@options.reverse_merge(soft: true))
65
+ reflection = object.public_send(reflection_name)
66
+ reflection.decorate(@options.reverse_merge(soft: true)) if reflection
66
67
  end
67
68
  end
68
69
  end
@@ -1,5 +1,5 @@
1
1
  module Light
2
2
  module Decorator
3
- VERSION = '0.5.2'.freeze
3
+ VERSION = '0.5.3'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: light-decorator
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Emelianenko
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-06-16 00:00:00.000000000 Z
11
+ date: 2016-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails