File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 33
33
"url" : " https://github.com/cthackers/adm-zip.git"
34
34
},
35
35
"engines" : {
36
- "node" : " >=0.3 .0"
36
+ "node" : " >=6 .0"
37
37
},
38
38
"devDependencies" : {
39
39
"chai" : " ^4.1.2" ,
Original file line number Diff line number Diff line change @@ -26,8 +26,8 @@ module.exports = function(/*String*/path) {
26
26
_obj . directory = _stat . isDirectory ( ) ;
27
27
_obj . mtime = _stat . mtime ;
28
28
_obj . atime = _stat . atime ;
29
- _obj . executable = ! ! ( 1 & parseInt ( ( _stat . mode & parseInt ( "777" , 8 ) ) . toString ( 8 ) [ 0 ] ) ) ;
30
- _obj . readonly = ! ! ( 2 & parseInt ( ( _stat . mode & parseInt ( "777" , 8 ) ) . toString ( 8 ) [ 0 ] ) ) ;
29
+ _obj . executable = ( 0o111 & _stat . mode ) != 0 ; // file is executable who ever har right not just owner
30
+ _obj . readonly = ( 0o200 & _stat . mode ) == 0 ; // readonly if owner has no write right
31
31
_obj . hidden = pth . basename ( _path ) [ 0 ] === "." ;
32
32
} else {
33
33
console . warn ( "Invalid path: " + _path )
You can’t perform that action at this time.
0 commit comments