Fixed crash in ts parser - thx Marilson :)