Skip to content

Commit

Permalink
remove the lint error
Browse files Browse the repository at this point in the history
  • Loading branch information
AyushNautiyalDeveloper committed Sep 26, 2023
1 parent 0c7dc9a commit 972cef0
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/commands/new/file.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,16 +160,13 @@ export default class NewFile extends Command {
console.log(`File ${fileNameToWriteToDisk} already exists. Ignoring...`);
return;
}
} catch (e:any ) {

} catch (e:any) {
if (e.code === 'EACCES') {
console.error('Permission denied to read the file. You do not have the necessary permissions.');
} else {
await writeFile(fileNameToWriteToDisk, asyncApiFile, { encoding: 'utf8' });
console.log(`Created file ${fileNameToWriteToDisk}...`);

}
}

}
}

0 comments on commit 972cef0

Please sign in to comment.