I have a formula (screenshot). I get an error saying “First parameter must be an array (or collection)”. But if I check my backups, from 5 days ago (second screenshot), I have the same formula and it is working just fine. No errors, it shows elements correctly etc… Why do I get the issue, so I can try to solve it?
@tcc hi!
As far as I can see, in the first screenshot, you have the variable "item.data[0], which is not an array, but the first element of an array. That’s why you got an error.
On the second screenshot you have a variable “item.data” which could be an array.
The formula is on the Stack Weweb element. On Friday I lost half of my stack element (I have a stack inside a stack), so I had to search in my backup to find the element back. If when I paste the backup element inside the Live version, I don’t get the results, however in the backup I still have them (even after changing the item.data).
I have the feeling Weweb was updating the element, that is why I lost half of the element and it is probably still not working well…
Ok, I understand what is wrong. If the result of a formula is empty, as there is no data for this filter, it doesn’t show the rest of the results from the formula. I have some formulas that give an empty result as there is no data for this filter (yet). Before it was working, that if there was no result for one part of the formula, it still showed the results within the formula that corresponded to one part of the filter. Any idea how to solve this easily?
Still, I don’t know your data structure, so I can’t come up with the best solution. However, what I would personally do is get rid of complex formulas (if possible). They’re hard to maintain.
I would use variable-bound logic with branching through workflows. But it’s just a guess.



