From d1c9321fdfb0eb794a6fae299912613c7f68e70e Mon Sep 17 00:00:00 2001 From: KillariDev Date: Tue, 24 Sep 2024 17:43:02 +0300 Subject: [PATCH] add missing awaits --- solidity/compile.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/solidity/compile.ts b/solidity/compile.ts index 5598da3..9f18680 100644 --- a/solidity/compile.ts +++ b/solidity/compile.ts @@ -36,8 +36,8 @@ const compilePetalLock = async () => { var output = compile(JSON.stringify(input)) const artifactsDir = path.join(process.cwd(), 'artifacts') - if (!exists(artifactsDir)) await fs.mkdir(artifactsDir, { recursive: false }) - fs.writeFile('artifacts/PetalLock.json', output) + if (!await exists(artifactsDir)) await fs.mkdir(artifactsDir, { recursive: false }) + await fs.writeFile(path.join(artifactsDir, 'PetalLock.json'), output) } compilePetalLock().catch(error => {