HPCC-8655 Fix ESP crash when running WUGetDependancyTrees

ESP crashes because the code uses a wu pointer which has been cleared.

Signed-off-by: Kevin Wang <kevin.wang@lexisnexis.com>