few minor js fixes