applied a fix in js;