@spamushere I don’t really see how 0 ends up as a string. 3000 lines of code is a lot to deal with, and we’re really unable to debug complex code.
What backend function are you calling? Do you know what in fact you are returning? You’ll need to find out why if it’s 0 you get undefined. Try some console.log() statements wherever you can to see what’s happening.
Number(0) doesn’t make sense, as 0 is already a number. However, I tried and it returns - wait for it… the number 0. Number(‘0’) would make more sense, and of course returns the number 0.