This fixes the removeWeak bug.  It precalculates the TS now before removing sources.