fix js syntax error, remove consolelogs