update items before removing them