servactory 2.13.0 → 2.13.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: effe21494947a824c5ee5f49b022a92157a69906a6b5f41cdf96a02b08bedc55
4
- data.tar.gz: 7d52a8e143393e05824426f6c62e2d767191cee35b106fc159f3c2d72bfab50e
3
+ metadata.gz: b763a59ba9addc399da0f21f95c1b48587a49754f2f67ec4c3cff52e3808840d
4
+ data.tar.gz: 7411b3254bbf61e2754c58432540260077c62f58912d881c716d1fb33d3757f2
5
5
  SHA512:
6
- metadata.gz: e10b019ae010c04a64fe28fc0e06b7e10d756ad7f6217e45c9241cc81c421fdbae8e36944de03b3de035aa307ed0b93a73a77e375fa218bfe198ed2a24a3e37a
7
- data.tar.gz: 511d7cb765402d1a3b1ce41d30d7abf1964a0070191a10aaa3eb0109089b8a5ad49dde6e6904e539c8a1cc4bfe5343e48a10f13df378b0ab8472ed02d6d584ef
6
+ metadata.gz: df8c6ee28efbe777a6a98bdc4bc1641fdc787a16105f9444418ddad6371e7b913ac3a0dc799c1eefb15d99c97e7b06637db4bb77f5432f3629f5a933524229bf
7
+ data.tar.gz: 58e1676c904cff6ac988fdd2616cb9c44768bde908a6364cc7d86fcbdbac417e4fefb664da6a47e6cdb9bd251c5fa0210b22111e3ae4179fb4810097c2bfc5f5
@@ -46,7 +46,13 @@ module Servactory
46
46
  return yield if input.nil?
47
47
 
48
48
  input_value = @context.send(:servactory_service_warehouse).fetch_input(input.name)
49
- input_value = input.default if input.optional? && input_value.blank?
49
+
50
+ if input.optional? && (
51
+ (!input_value.is_a?(TrueClass) && !input_value.is_a?(FalseClass) && input_value.blank?) ||
52
+ input_value.nil?
53
+ ) # do
54
+ input_value = input.default
55
+ end
50
56
 
51
57
  input_prepare = input.prepare.fetch(:in, nil)
52
58
  input_value = input_prepare.call(value: input_value) if input_prepare.present?
@@ -4,7 +4,7 @@ module Servactory
4
4
  module VERSION
5
5
  MAJOR = 2
6
6
  MINOR = 13
7
- PATCH = 0
7
+ PATCH = 1
8
8
  PRE = nil
9
9
 
10
10
  STRING = [MAJOR, MINOR, PATCH, PRE].compact.join(".")
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: servactory
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.13.0
4
+ version: 2.13.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anton Sokolov
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-03-06 00:00:00.000000000 Z
10
+ date: 2025-03-19 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: activesupport