removeExternalTrees is working