light-decorator 0.5.1 → 0.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/gemfiles/rails_4_0.gemfile.lock +1 -1
- data/gemfiles/rails_4_1.gemfile.lock +1 -1
- data/gemfiles/rails_4_2.gemfile.lock +1 -1
- data/gemfiles/rails_5_0.gemfile.lock +1 -1
- data/lib/light/decorator.rb +1 -3
- data/lib/light/decorator/decorate.rb +1 -1
- data/lib/light/decorator/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1b2cc38013100334f2c45e436c169ebbb85fdb9e
|
4
|
+
data.tar.gz: 2bf2245562ac16976d6e0d3c375fc7eba8124f9e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4e51d3e2e781813f986e62b768ed93eb0988e24217cf455af5eefe90288732dce0083faa05277de1e0906a35d25a14bfaf2a2e244d28603d3c8e22551ad9a557
|
7
|
+
data.tar.gz: cbed29f31d8ad962ed1c5c76e240f25b6cfadc7a3b648c1487f1a716672f1e92c4957f9ed57664a6c17c049ba7956b161db45697f3ec275b92288660eca66023
|
data/README.md
CHANGED
data/lib/light/decorator.rb
CHANGED
@@ -13,8 +13,6 @@ require 'light/decorator/decorate'
|
|
13
13
|
|
14
14
|
module Light
|
15
15
|
module Decorator
|
16
|
-
|
17
|
-
Kernel.methods + ActiveRecord::Base.methods + [:decorated?, :==, :===, :eql?, :equal?]
|
18
|
-
).freeze
|
16
|
+
FORCE_DELEGATE = [:to_param].freeze
|
19
17
|
end
|
20
18
|
end
|
@@ -52,7 +52,7 @@ module Light
|
|
52
52
|
|
53
53
|
def delegate_methods
|
54
54
|
# It's more faster than using Forwardable
|
55
|
-
(object.public_methods - methods
|
55
|
+
(object.public_methods - methods + Light::Decorator::FORCE_DELEGATE).each do |method|
|
56
56
|
define_singleton_method method do |*args, &block|
|
57
57
|
object.__send__(method, *args, &block)
|
58
58
|
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.
|
4
|
+
version: 0.5.2
|
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-
|
11
|
+
date: 2016-06-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|