From 9f7274abbd04da3c63cfcdd045505774630b9eaf Mon Sep 17 00:00:00 2001 From: Juri Leino Date: Sun, 22 Sep 2024 17:26:11 -0400 Subject: [PATCH] fix: add fallback description to router:error-description If the error raised does neither have a description nor a value it will now return "No description provided." --- content/router.xql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/router.xql b/content/router.xql index 9f8fb38..adbbee9 100644 --- a/content/router.xql +++ b/content/router.xql @@ -386,7 +386,7 @@ declare %private function router:error-description ($description as xs:string?, if ($line and $line > 0 and empty($value)) then ``[`{$description}` [at line `{$line}` column `{$column}` in module `{head(($module, 'unknown'))}`]]`` else - ($description, $value)[1] + ($description, $value, 'No description provided.')[1] }; (:~