Fix deleting of unused tags