protip 0.37.1 → 0.37.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: b29978429d180c9023e5b11f34c954942c7b3e020f2fff71dc492e603b7264af
4
- data.tar.gz: 9e9a92cda97821f100f26d63267e33058f1f11e552ed17c65778f5530eda1973
3
+ metadata.gz: 236eb63af48bf81e28875f5dcdef16158ba69db7785436f47013481bab29fd51
4
+ data.tar.gz: 948cede4acce33d7da2e13af36da7f51d35cd073327ca6d666759004afd15140
5
5
  SHA512:
6
- metadata.gz: a227d2e7c9737ab476b34147ed48b82923020f3bf91f6d9f2d03af2377b61dae50e942994b25f050fd45953a395ea6d35806c89c9ee5a1a1618700ebb4ab6615
7
- data.tar.gz: 1d86e0454c130c97ab6c02fbbab114c8152b11cd29338064c23a460e96250bc70d488a2fe8a7b3d487315df9f075f4b70288991af95e64908cf9c3692578f4fe
6
+ metadata.gz: 833843e0287ad841903526db31eb40daef4dfaa389b23ab7dd34643bdc508c5696ee2f58f8a2a51697558008f1205e0a0180361129a090f6adf34d7d54a14787
7
+ data.tar.gz: b799bb1e32e81541ffe1a90e3a64721df338ee5fe8e315bfbab83486e4e1212866705af804bfd55308d0f39a9e11d07e54fd0613c9de1dc933e34bbb82463196
@@ -243,7 +243,7 @@ module Protip
243
243
  def to_protobuf_value(field, value)
244
244
  if field.type == :message
245
245
  if nil == value
246
- nil
246
+ field&.default || field&.subtype&.msgclass&.new
247
247
  # This check must happen before the nested_resources check to
248
248
  # ensure nested messages are set properly
249
249
  elsif value.is_a?(field.subtype.msgclass)
@@ -1,3 +1,3 @@
1
1
  module Protip
2
- VERSION = '0.37.1'
2
+ VERSION = '0.37.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: protip
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.37.1
4
+ version: 0.37.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - AngelList