fixing JS formatting