Im iterating out multiple lists in js like this:
0 0 tracks track1
0 0 tracks track2
0 0 tracks track3
However, sometimes I might have an empty element at the end of the list:
0 0 tracks
I would like to be able to detect that the last list element is empty. I cant seem to do this inside the js object, or outside in Max.
In Max, ive tried using "zl len" to detect the size of the list, but Max seems to believe that the list element is there, even though it is empty.
The same goes for inside the js object. Ive tried using
if (var == "")
Even though the part of the list is empty, there seems to be no way of recognising that it is empty.
Id be really grateful if anyone has any insights to a way of working around this.
UPDATE: Finally ive got it "if (var == 0)"