From 032b5ae9dc7bba0b631da69fb2fdc3841be6b545 Mon Sep 17 00:00:00 2001 From: MihailRis Date: Sat, 26 Apr 2025 21:58:09 +0300 Subject: [PATCH] fix --- res/scripts/stdlib.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/res/scripts/stdlib.lua b/res/scripts/stdlib.lua index 76872cd6..d5cd34bd 100644 --- a/res/scripts/stdlib.lua +++ b/res/scripts/stdlib.lua @@ -228,7 +228,10 @@ function gui.template(name, params) local text = file.read(file.find("layouts/templates/"..name..".xml")) text = text:gsub("%%{([^}]+)}", function(n) local s = params[n] - if not s or #s == 0 then + if type(s) ~= "string" then + return s + end + if #s == 0 then return end local e = string.escape(s)