From db2d169a57d7972309acd79d724c15c156b4e9b5 Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Sun, 12 Jul 2015 09:55:49 +0200 Subject: [PATCH] debug: some applications don't have a name For example, when not playing, the new version of Spotify doesn't expose a name. Handle that when displaying window information. --- rc/debug.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rc/debug.lua b/rc/debug.lua index 03f45ac..25b4181 100644 --- a/rc/debug.lua +++ b/rc/debug.lua @@ -74,7 +74,7 @@ local function dbg_get(var, depth, indent) end else if vtype == "tag" or vtype == "client" then - name = " [" .. var.name:sub(1,10) .. "]" + name = " [" .. (var.name or '…'):sub(1,10) .. "]" end text = text .. vstring .. name or "" end