From 8072d717cfb6ccd3254875603b6d1efe20789be3 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Mon, 18 Feb 2019 08:34:59 +0100 Subject: [PATCH] Fix extra newline with legacy naughty layout Fixes https://github.com/awesomeWM/awesome/commit/9df77e5c765d1b523babcdbc6a45e6cbafebcc21#commitcomment-32354198. --- lib/naughty/layout/legacy.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/naughty/layout/legacy.lua b/lib/naughty/layout/legacy.lua index bf1a231f1..ca0729327 100644 --- a/lib/naughty/layout/legacy.lua +++ b/lib/naughty/layout/legacy.lua @@ -131,9 +131,8 @@ local escape_subs = { ['<'] = "<", ['>'] = ">", ['&'] = "&" } -- Cache the markup local function set_escaped_text(self) - local text, title = self.message or "", self.title or "" - - if title then title = title .. "\n" else title = "" end + local text = self.message or "" + local title = self.title and self.title .. "\n" or "" local textbox = self.textbox