From d3a1da476802560d94d99b3e7e7a88d966d1b4cf Mon Sep 17 00:00:00 2001 From: "i.gandacov" Date: Wed, 2 Aug 2023 17:21:25 +0200 Subject: [PATCH] DP-931 cleanup --- src/services/file-service.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/services/file-service.ts b/src/services/file-service.ts index aa4c20b..1426b90 100644 --- a/src/services/file-service.ts +++ b/src/services/file-service.ts @@ -18,13 +18,15 @@ export class FileService { } public readManifestFile(importedFileName: string): Promise { - const manifest: ManifestNodeTransport[] = YAML.parse(fs.readFileSync(path.resolve(importedFileName + "/manifest.yml"), { encoding: "utf-8" })); + const manifest: ManifestNodeTransport[] = YAML.parse( + fs.readFileSync(path.resolve(importedFileName + "/manifest.yml"), { encoding: "utf-8" }) + ); return Promise.all(manifest); } public readFile(filename: string): string { if (!fs.existsSync(path.resolve(process.cwd(), filename))) { - logger.error(new FatalError("The provided file does not exit")); + logger.error(new FatalError(`The provided file '${filename}' does not exit`)); } return fs.readFileSync(path.resolve(process.cwd(), filename), { encoding: "utf-8" }); }