Why output not removing empty values?

First script I wrote in Snap is broken
What's problem you are encountering?
I'd like the output to delete empty items from my list.
What have you tried that didn't work?
Yes
Post a project example, link, or screenshot:
Skärmavbild 2021-03-12 kl. 22.52.28

What does the block "remove # from entity" do?
Also, why are you trying to split a list?

Hi, welcome to Snap!.

The problem is in your first instruction. The LIST block creates a list of length 1, not a text string.
But SPLIT, in the second instruction, expects a text string. So what it's doing is splitting the one item of your list into a list of three, which becomes the first and only item of a one-item list. You're then deleting empty items from that one-item list, but there aren't any empty items.

To understand this better, run the code one line at a time, and display the value of ENTITY after each line.

Thank you! :heart:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.