Fix EACCES error code name
This commit is contained in:

committed by
Jamie Kyle

parent
58d53527e0
commit
16c9c17cc2
@@ -75,7 +75,7 @@ async function doGracefulRename({
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error.code !== 'EACCESS' && error.code !== 'EPERM') {
|
if (error.code !== 'EACCES' && error.code !== 'EPERM') {
|
||||||
throw error;
|
throw error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -69,7 +69,7 @@ export function createRotatingPinoDest({
|
|||||||
// delay.
|
// delay.
|
||||||
if (
|
if (
|
||||||
retryCount < MAX_RETRY_COUNT &&
|
retryCount < MAX_RETRY_COUNT &&
|
||||||
(error.code === 'EACCESS' || error.code === 'EPERM')
|
(error.code === 'EACCES' || error.code === 'EPERM')
|
||||||
) {
|
) {
|
||||||
retryCount += 1;
|
retryCount += 1;
|
||||||
warn(`rotatingPinoDest: retrying rotation, retryCount=${retryCount}`);
|
warn(`rotatingPinoDest: retrying rotation, retryCount=${retryCount}`);
|
||||||
|
Reference in New Issue
Block a user