Problems with returning Wix Data by function

It’s not so clear what you’re trying to do:

  1. read the docs https://www.wix.com/velo/reference/wix-data/query

  2. . please rewrite the code so the look function declaration won’t be inside export event handler.

  3. your query has no parameters, add them to the query.

  4. do not run the query 21 times, use .hasSome() to run it one time.

  5. If it still doesn’t work, post the the corrected code here in a code block