Countdown timer expression error
I'm trying to make a countdown timer from text
, counting down from 10 minutes. I'm using an expression on a Slider Control that has always worked but it seems like it doesn't work with the latest update.
This is the expression I'm using:
slider = Math.round(effect("Slider Control")("Slider"))
sec = slider%60
min = Math.floor(slider/60)
function addZero(n){ if (n<10) return "0" + n else return n }
addZero(min) + ":" + addZero(sec)
I got the error on line 4:'' Error; SyntaxError; Unexpected 'else'
If anyone has any suggestions I would really appraciate the help!
