blueprinter 1.1.1 → 1.1.2

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
  SHA256:
3
- metadata.gz: d6126b25a4c6b88be36bd59b5bf18c6fa9fcc7f33815fb78679eab249e1b7992
4
- data.tar.gz: a29d92d2db99389c97d55235cc1f762bacc0b9841909f2ad3413013874546a9c
3
+ metadata.gz: ca694fd9e2b31d1b48e7fafb2637a67b2e83835d90d51126dfa5c2520147b4b1
4
+ data.tar.gz: eb7dbb1f64149a475a4b768883fac8d9b8d20e6dad061a1f2ceadd5f1aa10a35
5
5
  SHA512:
6
- metadata.gz: ab403215f43e966541dfc40b18a992fc713e1e490a6c03e304554f9e79416618333d44c1ae6bc2efbe1a30812bd36c23e64c43ce9877a1a573564bde7bff2b5f
7
- data.tar.gz: aac7c74b4611e4ae5952d224365a7f0184e056aca8a0ec6431c3518370408fec6cc7d9ba55889c2504912edadb33e69935bb62f152f50d337e117bd10a762110
6
+ metadata.gz: a8fee9e8d383bd1f7fcf92124373cd06070327e16264f5d8dd281c18a8393f7bea9eea6a93252e30d46f899063c4e2bf2a79e0b7d7af2e890a847b8a03af766a
7
+ data.tar.gz: 8971833f761e56d13e41a93c688ecca7d7c1213e432db0f61ba8786c9f68851b1978f0bbb6618e5c935bd8e07c6268d3e8bcc5f5e57f6e188e78a83322253bc0
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 1.1.2 - 2024/10/3
2
+ - 🐛 [BUGFIX] Fixes an issue where a `Blueprinter::BlueprinterError` would be raised on render when providing `view: nil`, instead of falling back on the `:default` view. See
3
+ [#472](https://github.com/procore-oss/blueprinter/pull/472). Thanks to [@lessthanjacob](https://github.com/lessthanjacob).
4
+
1
5
  ## 1.1.1 - 2024/10/2
2
6
  * 🐛 [BUGFIX] Fixes an issue when when calling `.render` multiple times on a Blueprint using the same `options` hash, which would result in the `options` changing unexpectedly between calls. See [#453](https://github.com/procore-oss/blueprinter/pull/453). Thanks to [@ryanmccarthypdx](https://github.com/ryanmccarthypdx).
3
7
  * 🐛 [BUGFIX] Fixes an issue when passing in a `Symbol` (representing a method) to the `if:` condition on an association. The provided `Symbol` would be erroneously sent to the association's Blueprint, instead of the Blueprint in which the association was defined within. See [#464](https://github.com/procore-oss/blueprinter/pull/464). Thanks to [@lessthanjacob](https://github.com/lessthanjacob).
@@ -15,7 +15,7 @@ module Blueprinter
15
15
  private
16
16
 
17
17
  def prepare_for_render(object, options)
18
- view_name = options.fetch(:view, :default)
18
+ view_name = options.fetch(:view, :default) || :default
19
19
  root = options[:root]
20
20
  meta = options[:meta]
21
21
  validate_root_and_meta!(root, meta)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Blueprinter
4
- VERSION = '1.1.1'
4
+ VERSION = '1.1.2'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blueprinter
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Procore Technologies, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-10-03 00:00:00.000000000 Z
11
+ date: 2024-10-04 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Blueprinter is a JSON Object Presenter for Ruby that takes business objects
14
14
  and breaks them down into simple hashes and serializes them to JSON. It can be used