diff --git a/core.lua b/core.lua index 8dc334b..7b4daaa 100644 --- a/core.lua +++ b/core.lua @@ -253,13 +253,14 @@ function Aux.AuctionFrameAuctions_OnEvent(...) end function Aux.on_auction_house_show() - if not UnitFactionGroup('npc') then - Aux.neutral = true - end AuxFrame:Show() Aux.tab_group:set_tab(1) end +function Aux.neutral_faction() + return not UnitFactionGroup('npc') +end + function Aux.on_auction_house_closed() Aux.post.stop() Aux.stack.stop() diff --git a/post_frame.lua b/post_frame.lua index be09e35..91df65e 100644 --- a/post_frame.lua +++ b/post_frame.lua @@ -615,7 +615,7 @@ function private.update_item_configuration() private.stack_count_slider.editbox:SetNumber(private.stack_count_slider:GetValue()) do - local deposit_factor = Aux.neutral and 0.25 or 0.05 + local deposit_factor = Aux.neutral_faction() and 0.25 or 0.05 local stack_size = private.stack_size_slider:GetValue() local stack_count stack_count = private.stack_count_slider:GetValue()