Various ts() usage fixes.