Skip to content

Commit

Permalink
added existsSync sourceDataFilePath test into DecoderLecoGithubTransf…
Browse files Browse the repository at this point in the history
…ormer's constructor
  • Loading branch information
BorisTherin committed Apr 8, 2024
1 parent 28baf3a commit e377c25
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/transformers/DecoderLecoGithubDataTransformer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ export class DecoderLecoGithubDataTransformer {
* @param transformedDataFilePath The path to the file in which the transformed data will be persisted. E.g. `./transformedData/proj_19np_transformed.csv`, the path must begin with './'.
*/
constructor(protected sourceDataFilePath: string, protected transformedDataFilePath: string) {
if (!fs.existsSync(this.sourceDataFilePath))
throw new Error(`${this.sourceDataFilePath} doesn't exists`)
this.sourceDataFilePath = sourceDataFilePath
this.transformedDataFilePath = transformedDataFilePath
/**
Expand Down

0 comments on commit e377c25

Please sign in to comment.