fixed items being deleted when they shouldn't be