dry-bot on master
[devtools] sync (compare)
flash-gordon on master
It's 2021 everyone! (compare)
flash-gordon on v1.5.0
dry-bot on master
[devtools] sync (compare)
flash-gordon on master
Set release date (compare)
flash-gordon on master
Add docs for fallbacks and cust… (compare)
dry-bot on master
[devtools] sync (compare)
flash-gordon on master
Update changelog.yml (compare)
Base
as default there but Dry::Struct
Hi guys, it seems that I maybe encounter a bug of dry-types SUM
, but I'm not sure. Could you help me on this?
It happens when I try to verify a object which should be a hash or a string
test = Dry::Types['hash'].map(Dry::Types['symbol'], Dry::Types['strict.string']) | Dry::Types['strict.string']
test[a: 'b'] # passed as expected
test['a' => 'b'] # should fail but pass!
test['test'] # passed as expected
test[12345] # should fail but pass!
I'm wondering if there is anything that I didn't notice or I use the wrong way to build my rule. Thanks :)
Links = Map(Symbol, String | JSONAPI::Types::Link.optional)