Fixing bad generated javascript (sorry everyone) :(