update js for clarity