Removed debugger and fixed dom bug