bug fix in web.js