foobara 0.0.64 → 0.0.65

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: 57076f6987a22c895a9ce9b024b2a7e05ffcaa5d96719dedc168cb029404a185
4
- data.tar.gz: b1616575b7778d1ff2597a4c208fda89e544dbe77f3bf0a1ee724c6d5e753aae
3
+ metadata.gz: 21197ef384605690acb82fc34c7e05508e876b9659ff7aeb3cb068b9f3d2e43f
4
+ data.tar.gz: 9fa7bb5281ce36f1b62b57860e29b618d58d1ae18b3a6e9212e370549d1b0f6f
5
5
  SHA512:
6
- metadata.gz: bfb5adcce767f972f766372d23a473ca5598eb281809b5ee64a62e4a08265326e8aae3c6a6698be9cb3a1dedf87f8e32e33bd75a416181fcca7c2cdce2c0d05a
7
- data.tar.gz: b2654dadfc19dda6fa4019715ede5b7ad0bc06e17232dff595cdeeff6ddfdd0da2bbf5e7df42b2f63d66a5ba56eed4d38d6c4e6dffcf2823ca001ac7ddd8a0dc
6
+ metadata.gz: 43f5d7f1caf9380fd20d3b68a277e43c1a2efbcf226096892c2cc9cfaed8dbfc7591a16024f01a4e57f6e3c0bb590f04e8bfb823007b353dbe15ca735e4a9d1b
7
+ data.tar.gz: 97bbe6d2d1c24827ca1210713b7e65e3f63dfb69bf7a312aab4f3631b4bf867b41dcdd2a9692cb626d563ad4166e433955dbf5bfd1d1154ac950b902bb0df0ce
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## [0.0.65] - 2025-02-26
2
+
3
+ - Fix a problem when looking up domain mappers with a symbol value that doesn't represent a type
4
+
1
5
  ## [0.0.64] - 2025-02-25
2
6
 
3
7
  - Fix bug where DomainMappers created after commands have ran wouldn't be detected
@@ -58,7 +58,7 @@ module Foobara
58
58
 
59
59
  type = object_to_type(type_indicator)
60
60
 
61
- return 1 if type.nil?
61
+ return 0 if type.nil?
62
62
  return 9 if type == value
63
63
 
64
64
  return 5 if type.applicable?(value) && type.process_value(value).success?
@@ -104,7 +104,7 @@ module Foobara
104
104
  when Types::Type
105
105
  object
106
106
  when ::Symbol
107
- domain.foobara_lookup_type!(object)
107
+ domain.foobara_lookup_type(object)
108
108
  end
109
109
  end
110
110
  end
@@ -154,6 +154,10 @@ module Foobara
154
154
  def target_class
155
155
  if target_classes.empty?
156
156
  # :nocov:
157
+ # TODO: We really need a better error message when we hit this point in the code path.
158
+ # One thing that can cause this is if you create a custom type called :model but it isn't loaded
159
+ # yet and we accidentally are referring to the builtin :model type. This error message doesn't reveal
160
+ # that you need to require the custom :model.
157
161
  raise "No target classes"
158
162
  # :nocov:
159
163
  elsif target_classes.size > 1
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foobara
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.64
4
+ version: 0.0.65
5
5
  platform: ruby
6
6
  authors:
7
7
  - Miles Georgi
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-02-25 00:00:00.000000000 Z
10
+ date: 2025-02-26 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: bigdecimal