javascript to address issues on qa

javascript issues seem to be causing issue on qa. 
same as above regarding comment