Clear out before connecting.

Since the node set may have been altered since the
last connect we want to make sure clear out the
edges and the providers of items before connecting.

Change-Id: I73e6b3bc5d83a82d2b13dbb6b06c66e794d66e9c
Merge "Clear out before connecting."