mirror of
https://github.com/nodemailer/wildduck.git
synced 2025-03-01 10:24:40 +08:00
do not use finally
This commit is contained in:
parent
e7d40d5ce2
commit
cf8d8f28cd
1 changed files with 8 additions and 8 deletions
|
@ -43,19 +43,19 @@ async function mboxExport(auditHandler, audit) {
|
|||
|
||||
setImmediate(() => {
|
||||
processExport()
|
||||
.catch(err => {
|
||||
try {
|
||||
outputStream.write('\n' + err.message);
|
||||
} catch (err) {
|
||||
//ignore
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
.then(() => {
|
||||
try {
|
||||
outputStream.end();
|
||||
} catch (err) {
|
||||
// ignore at this point
|
||||
}
|
||||
})
|
||||
.catch(err => {
|
||||
try {
|
||||
outputStream.end('\n' + err.message);
|
||||
} catch (err) {
|
||||
//ignore
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue