Skip to content

Commit 2d42170

Browse files
committedApr 3, 2020
Remove unnecessary process.umask()
Fix #22 Re nodejs/node#32321
1 parent 4d59b81 commit 2d42170

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed
 

‎lib/opts-arg.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ const { promisify } = require('util')
22
const fs = require('fs')
33
const optsArg = opts => {
44
if (!opts)
5-
opts = { mode: 0o777 & (~process.umask()), fs }
5+
opts = { mode: 0o777, fs }
66
else if (typeof opts === 'object')
7-
opts = { mode: 0o777 & (~process.umask()), fs, ...opts }
7+
opts = { mode: 0o777, fs, ...opts }
88
else if (typeof opts === 'number')
99
opts = { mode: opts, fs }
1010
else if (typeof opts === 'string')

‎test/opts-arg.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
const t = require('tap')
22
const optsArg = require('../lib/opts-arg.js')
3-
const umask = process.umask()
4-
const mode = 0o777 & (~umask)
3+
const mode = 0o777
54
const fs = require('fs')
65

76
const defFs = {

0 commit comments

Comments
 (0)
Please sign in to comment.