Fix checking of output path argument