Fork me on GitHub
#malli
<
2022-08-26
>
Setzer2213:08:19

Hi! We've just noticed that schemas using a registry don't work with methods from malli utils, is this intended? This works as expected:

(m/entries [:map [:hola :string]]) ; => ([:hola [:malli.core/val :string]])
But this fails (returns nil, but the schema is the same)
(m/entries [:schema 
            {:registry {"Foo" [:map [:hola :string]]}}
            "Foo"]) ; => nil

Noah Bogart14:08:58

You need m/deref-all :

(m/entries
  (m/deref-all
    [:schema {:registry {"Foo" [:map [:hola :string]]}}
     "Foo"]))
;=> ([:hola [:malli.core/val :string]])

Setzer2214:08:40

awesome, thanks! 👍