Fixed Union Find connected method