Handle deleted items properly in backend