update unionfind usage