changed javascript modules - minor syntax changes