When entities are ordered to repair a foundation, and the foundations is repaired while the unit is approaching, the unit will look for a new foundation.
It seems better to look near the target than near the unit.
Open question: should there be a distance cutoff for the "look near me" fallback?