Fixes minor js bug