JS: regression fix from previous commit.