Skip to content

Commit b662204

Browse files
coreyfarrellsindresorhus
authored andcommitted
Update write-file-atomic dependency (#25)
1 parent 879e140 commit b662204

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ const makeDir = require('make-dir');
88
const detectIndent = require('detect-indent');
99

1010
const readFile = promisify(fs.readFile);
11-
const writeFileAtomicP = promisify(writeFileAtomic);
1211

1312
const init = (fn, filePath, data, options) => {
1413
if (!filePath) {
@@ -51,7 +50,7 @@ const main = async (filePath, data, options) => {
5150

5251
const json = JSON.stringify(data, options.replacer, indent);
5352

54-
return writeFileAtomicP(filePath, `${json}\n`, {mode: options.mode});
53+
return writeFileAtomic(filePath, `${json}\n`, {mode: options.mode});
5554
};
5655

5756
const mainSync = (filePath, data, options) => {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"graceful-fs": "^4.1.15",
3939
"make-dir": "^3.0.0",
4040
"sort-keys": "^3.0.0",
41-
"write-file-atomic": "^2.4.2"
41+
"write-file-atomic": "^3.0.0"
4242
},
4343
"devDependencies": {
4444
"ava": "^1.4.1",

0 commit comments

Comments
 (0)