Avoid calling PATH.join on null or undefined.