Fix silly js mistakes