Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This fully addresses issue Knowcode-AI#5 and contributes to my issue K…
…nowcode-AI#6 The /media/drawable directory does not exist when the extension is initially installed, yet the createOrShow() function calls fs.rmdirSync recursively, which throws an error on the non-existing drawable directory (media exists). I've wrapped this call up with an fs.existsSync, which will perform the existing action if the directory exists, otherwise it calls fs.mkdirSync with the same options as the call to fs.rmdirSync (i.e, recursive: true) The extension will now execute successfully on an initial install without the user having to create the subdirectory tree manually.
- Loading branch information