rostermanager: Rename variable to avoid name clash [luacheck]
authorKim Alvefur <zash@zash.se>
Sat, 9 Jan 2016 14:18:46 +0000 (15:18 +0100)
committerKim Alvefur <zash@zash.se>
Sat, 9 Jan 2016 14:18:46 +0000 (15:18 +0100)
core/rostermanager.lua

index f196ccf3a1ef043ab78606d388265b36ce953da4..0b72d0a62514ff918872364ca9961d48eb954ea9 100644 (file)
@@ -300,17 +300,17 @@ local function unsubscribed(username, host, jid)
        if pending then
                roster[false].pending[jid] = nil;
        end
-       local subscribed;
+       local is_subscribed;
        if item then
                if item.subscription == "from" then
                        item.subscription = "none";
-                       subscribed = true;
+                       is_subscribed = true;
                elseif item.subscription == "both" then
                        item.subscription = "to";
-                       subscribed = true;
+                       is_subscribed = true;
                end
        end
-       local success = (pending or subscribed) and save_roster(username, host, roster);
+       local success = (pending or is_subscribed) and save_roster(username, host, roster);
        return success, pending, subscribed;
 end