js warning on delete