blueprinter 0.13.1 → 0.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/blueprinter/extractors/association_extractor.rb +2 -1
- data/lib/blueprinter/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d690704c8da95e946025db00e856ad92d4c88366b5d3a86540e1a2f1f12561d4
|
|
4
|
+
data.tar.gz: 5e614e3a81094e274517427b5657a95aa8f35e8a479ffd0ef0827ac6558dc90b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cba3479c4473c7ec3c28b3a03470ad9524ec949f0107bf093abaa2ac79eae16712cf9df9a322fac2f6c333d20a6ed1e3bd4c748b4460f4c7b3f0fc8d11abaf1f
|
|
7
|
+
data.tar.gz: 7d1161cac2b2b090545fb6658d3c049b97cbe2fe58a0024890789315565586b38e5d65b4e23b53b17f99ee492529a7aa266d7633848a0c21ab165ec364056e22
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
## 0.13.2 - 2019/03/14
|
|
2
|
+
* 🐛 [BUGFIX] Replacing use of rails-specific method `Hash::except` so that Blueprinter continues to work in non-Rails environments. [#140](https://github.com/procore/blueprinter/pull/140). Thanks to [@checkbutton](https://github.com/checkbutton).
|
|
3
|
+
|
|
1
4
|
## 0.13.1 - 2019/03/02
|
|
2
5
|
* 💅 [MAINTENANCE | ENHANCEMENT] Cleaning up the `include_associations` section. This is not a documented/supported feature and is calling `respond_to?(:klass)` on every object passed to blueprinter. [#139](https://github.com/procore/blueprinter/pull/139). Thanks to [@ritikesh](https://github.com/ritikesh).
|
|
3
6
|
|
|
@@ -5,7 +5,8 @@ module Blueprinter
|
|
|
5
5
|
end
|
|
6
6
|
|
|
7
7
|
def extract(association_name, object, local_options, options={})
|
|
8
|
-
|
|
8
|
+
options_without_default = options.reject { |k,_| k == :default }
|
|
9
|
+
value = @extractor.extract(association_name, object, local_options, options_without_default)
|
|
9
10
|
return default_value(options) if value.nil?
|
|
10
11
|
view = options[:view] || :default
|
|
11
12
|
blueprint = association_blueprint(options[:blueprint], value)
|
data/lib/blueprinter/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: blueprinter
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.13.
|
|
4
|
+
version: 0.13.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Adam Hess
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2019-03-
|
|
12
|
+
date: 2019-03-14 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: factory_bot
|
|
@@ -200,7 +200,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
200
200
|
- !ruby/object:Gem::Version
|
|
201
201
|
version: '0'
|
|
202
202
|
requirements: []
|
|
203
|
-
rubygems_version: 3.0.
|
|
203
|
+
rubygems_version: 3.0.3
|
|
204
204
|
signing_key:
|
|
205
205
|
specification_version: 4
|
|
206
206
|
summary: Simple Fast Declarative Serialization Library
|