path.join throws error when null is passed as destDir to textReplaceFileTree()