Minor js fixes