counstructPathToFile static method
When asFolder
is true
, pathToFile
was a path to folder.
Implementation
static void counstructPathToFile(
String pathToFile, {
bool asFolder = false,
}) {
final dir = asFolder ? pathToFile : ph.dirname(pathToFile);
Directory(dir).createSync(recursive: true);
}