Added updated JavaScript