From: Jo-Philipp Wich Date: Mon, 21 Nov 2022 11:20:58 +0000 (+0100) Subject: luci-base: expose sysauth rendering errors X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=c4d86c9f670a31e4541ccdf1876be3ab8b98ee5c;p=project%2Fluci.git 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 --- 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); }