cope with renumbered nodes properly