From 86eb48edff558fc5611049a94ac55b9039d6667f Mon Sep 17 00:00:00 2001 From: Gerard Hickey Date: Mon, 19 Aug 2024 01:56:31 -0400 Subject: [PATCH] fix: Update zone name discovery to ignore icon metadata (#52) Signed-off-by: Gerard Hickey --- meshchatlib.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/meshchatlib.lua b/meshchatlib.lua index f409ea2..e9a4492 100755 --- a/meshchatlib.lua +++ b/meshchatlib.lua @@ -89,7 +89,10 @@ function zone_name() if nixio.fs.access(servfile) then for line in io.lines(servfile) do - local zone = line:match("^(.*)|.*|.*|.*|.*|meshchat$") + -- this will match the new service names with the icon metadata + -- in this case we are using a space or a pipe to terminate + -- the service name + local zone = line:match("^(.-)[%s%|].*|meshchat$") if zone then return zone end