Hey Kirby,
I’m still trying to wrap my head around the new Fetch functionality inside Blueprints. Like here.
I set up a tag field inside my site.yml that should define wich tags can be used in other blueprints.
When i then insert the code from the link above inside my other blueprints:
Argument 1 passed to Kirby\Cms\StructureObject::setContent() must be of the type array or null, string given, called in /homepages/40/d231701815/htdocs/urbantypes/kirby/src/Toolkit/Properties.php on line 130
Wich makes sense I guess, because the tag content is already an Array. But when I rewrite the blueprint to just fetch: site.tags it gives me an Invalid query result data error. What kind of data should be fetched by the query?
Yes, @flokosiol is right, in the example, a structure field is used to define the possible tags, not a tags field, hence the toStructure method in the query (the example code was based on an older Starterkit example). Might be a confusing that the field is also called tags and we could be more explicit about what we are referring to… Still work in progress. I added a note in the docs repo to add more explanations.