From 39357763b6c166b0b461ae2fdc08bfd7ec272610 Mon Sep 17 00:00:00 2001 From: Noel Forte Date: Fri, 6 Dec 2024 17:32:29 -0500 Subject: [PATCH] replace `||` with `??` when assigning to `nextRef.originalError` --- src/Errors/EleventyErrorHandler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Errors/EleventyErrorHandler.js b/src/Errors/EleventyErrorHandler.js index 90ad4dc34..962cb8b7b 100644 --- a/src/Errors/EleventyErrorHandler.js +++ b/src/Errors/EleventyErrorHandler.js @@ -93,7 +93,7 @@ class EleventyErrorHandler { // Unwrap cause from error and assign it to what Eleventy expects if (nextRef?.cause) { - nextRef.originalError = nextRef.cause?.originalError || nextRef?.cause; + nextRef.originalError = nextRef.cause?.originalError ?? nextRef?.cause; } if (!nextRef && EleventyErrorUtil.hasEmbeddedError(ref.message)) {