From ed78643b725b581d21ab994982a871ced42e9119 Mon Sep 17 00:00:00 2001 From: Supergoat666 <47240900+Supergoat666@users.noreply.github.com> Date: Tue, 25 Aug 2020 12:22:03 +0200 Subject: [PATCH] use get_player_factions if possible --- chatcommands.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chatcommands.lua b/chatcommands.lua index 9b8cb29..309d9a6 100644 --- a/chatcommands.lua +++ b/chatcommands.lua @@ -303,7 +303,7 @@ if areas.factions_available then end if (factions.version or 0) < 2 or factions.mode_unique_faction then -- Single faction mode - local open = not areas.areas[id].faction_open and {factions.get_player_faction(name)} + local open = not areas.areas[id].faction_open and ((factions.version or 0) < 2 and {factions.get_player_faction(name)}) or factions.get_player_factions(name) -- Save false as nil to avoid inflating the DB. areas.areas[id].faction_open = open or nil areas:save()