fix rmDir deprecation warning
This commit is contained in:
parent
799423629a
commit
84f4262176
|
@ -60,7 +60,7 @@ function fixLngFile(lng) {
|
||||||
if (resStr !== jsonStr) {
|
if (resStr !== jsonStr) {
|
||||||
let err;
|
let err;
|
||||||
if (resStr === '{}') {
|
if (resStr === '{}') {
|
||||||
fs.rmdirSync(`${DIR}${lng}`, {recursive: true});
|
fs.rmSync(`${DIR}${lng}`, {recursive: true, force: true});
|
||||||
err = 'no translations -> deleted';
|
err = 'no translations -> deleted';
|
||||||
} else {
|
} else {
|
||||||
fse.outputFileSync(makeFileName(lng), resStr + '\n');
|
fse.outputFileSync(makeFileName(lng), resStr + '\n');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user