diff options
author | Rebecca Turner <me@re-becca.org> | 2017-05-10 10:07:43 +0300 |
---|---|---|
committer | Rebecca Turner <me@re-becca.org> | 2017-05-26 04:55:10 +0300 |
commit | ecfa3713f85307b5724a5d9aea167190adfd7e6e (patch) | |
tree | 3e1e13bfce5decc59888a5e684856e0317e9e988 /lib | |
parent | fda9696523fe6e2d357736f2e2e7f6403ee73472 (diff) |
doctor: Make access checks v4 compatible
Diffstat (limited to 'lib')
-rw-r--r-- | lib/doctor/check-files-permission.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/doctor/check-files-permission.js b/lib/doctor/check-files-permission.js index 687a90088..50014fd23 100644 --- a/lib/doctor/check-files-permission.js +++ b/lib/doctor/check-files-permission.js @@ -38,7 +38,9 @@ function checkFilesPermission (root, mask, cb) { tracker.completeWork(1) if (e) return next(e) if (!stat.isFile()) return next() - fs.access(file, fs.constants.R_OK | fs.constants.W_OK, (err) => { + // 6 = fs.constants.R_OK | fs.constants.W_OK + // constants aren't available on v4 + fs.access(file, 6, (err) => { if (err) { tracker.error('checkFilePermissions', `Missing permissions on ${file}`) return next(new Error('Missing permissions for ' + file)) |