diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/modules/gamepath.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/modules/gamepath.js b/src/modules/gamepath.js index 5a5f922..0209d1b 100644 --- a/src/modules/gamepath.js +++ b/src/modules/gamepath.js @@ -91,6 +91,10 @@ gamepath.has_perms = (folder) => { fs.constants.R_OK | fs.constants.W_OK ) + let test_file_path = path.join(folder || settings().gamepath, ".viper_test"); + fs.writeFileSync(test_file_path, ""); + fs.unlinkSync(test_file_path); + return true; } catch (err) { return false; |