cleaned js syntax