fix globbing and check that all trees exist before tree2array