simplify controller js syntax, thanks @tka++