fixed js delete error