fix slash trail in javascript variable.