ensure target dir is correct