We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b9a805f + c7cdeaa commit 5a1f346Copy full SHA for 5a1f346
ingestion/src/process/prepare/codebase.ts
@@ -40,12 +40,13 @@ export class Codebase {
40
}
41
42
private initializeDataDirectory(removeExisting = false): void {
43
- this._dataDirName = "data" || uuid()
+ this._dataDirName = uuid()
44
this._dataDirPath = path.resolve(this._path, this._dataDirName)
45
46
/* Handle data directory */
47
- if (removeExisting && existsSync(this._dataDirPath)) rmSync(this._dataDirPath, { recursive: true })
48
- // mkdirSync(this._dataDirPath)
+ const exists = existsSync(this._dataDirPath)
+ if (removeExisting && exists) rmSync(this._dataDirPath, { recursive: true })
49
+ if (!exists) mkdirSync(this._dataDirPath)
50
51
52
private prepareFilesMetadata() {
0 commit comments