Fix token assignment bug.