fixed little error in javascript