From 9f53fd30a9647f63209273a39c384e3e6807ecce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20Sch=C3=A4fer?= Date: Sat, 16 Nov 2024 09:12:11 +0100 Subject: mod_roster: do not store number in attribute Attributes are strings. That definitely is a number. So we tostring() it. This is important when the API becomes stricter, for whatever reason that might happen. Practically, this moves the overhead of converting to a string to a place where it is visible. --- plugins/mod_roster.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins/mod_roster.lua') diff --git a/plugins/mod_roster.lua b/plugins/mod_roster.lua index 53b404f7..82016d27 100644 --- a/plugins/mod_roster.lua +++ b/plugins/mod_roster.lua @@ -56,7 +56,7 @@ module:hook("iq/self/jabber:iq:roster:query", function(event) roster:up(); -- move out from item end end - roster.tags[1].attr.ver = server_ver; + roster.tags[1].attr.ver = tostring(server_ver); end session.send(roster); session.interested = true; -- resource is interested in roster updates -- cgit v1.2.3