From c4d86c9f670a31e4541ccdf1876be3ab8b98ee5c Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Mon, 21 Nov 2022 12:20:58 +0100 Subject: [PATCH] luci-base: expose sysauth rendering errors In case a theme shipped sysauth.htm failed to render/execute, expose the exception error details in the ui theme fallback indicator. Signed-off-by: Jo-Philipp Wich --- modules/luci-base/ucode/dispatcher.uc | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/luci-base/ucode/dispatcher.uc b/modules/luci-base/ucode/dispatcher.uc index 89ff391939..b08a2f8b7a 100644 --- a/modules/luci-base/ucode/dispatcher.uc +++ b/modules/luci-base/ucode/dispatcher.uc @@ -921,6 +921,7 @@ dispatch = function(_http, path) { runtime.render(`themes/${basename(runtime.env.media)}/sysauth`, scope); } catch (e) { + runtime.env.media_error = `${e}`; runtime.render('sysauth', scope); }