From 05c0f1a4f4f86e06e3fbca8871d4ec9353fac8f8 Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 6 Dec 2018 00:08:04 +0800 Subject: [PATCH] fix lua51 bug --- src/ltui/border.lua | 2 +- src/ltui/window.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ltui/border.lua b/src/ltui/border.lua index 6aec092..6c85d86 100644 --- a/src/ltui/border.lua +++ b/src/ltui/border.lua @@ -39,7 +39,7 @@ function border:init(name, bounds) view.init(self, name, bounds) -- check bounds - assert(self:width() > 2 and self:height() > 2, string.format("%s: too small!", self)) + assert(self:width() > 2 and self:height() > 2, string.format("%s: too small!", tostring(self))) end -- draw border diff --git a/src/ltui/window.lua b/src/ltui/window.lua index a49cd11..4cb7da8 100644 --- a/src/ltui/window.lua +++ b/src/ltui/window.lua @@ -43,7 +43,7 @@ function window:init(name, bounds, title, shadow) panel.init(self, name, bounds) -- check bounds - assert(self:width() > 4 and self:height() > 3, string.format("%s: too small!", self)) + assert(self:width() > 4 and self:height() > 3, string.format("%s: too small!", tostring(self))) -- insert shadow if shadow then