GarrisonCommander

GarrisonCommander

4M Downloads

When clicking the minimap button to open the Dragonflight renowns, this error pops up every time.

TheKrowi opened this issue ยท 1 comments

commented

When clicking the minimap button to open the Dragonflight renowns, this error pops up every time.

Message: Interface/AddOns/GarrisonCommander/minimap.lua:20: attempt to index global 'GarrisonLandingPage' (a nil value)
Time: Sat Dec 17 07:44:43 2022
Count: 1
Stack: Interface/AddOns/GarrisonCommander/minimap.lua:20: attempt to index global 'GarrisonLandingPage' (a nil value)
[string "@Interface/AddOns/GarrisonCommander/minimap.lua"]:20: in function <Interface/AddOns/GarrisonCommander/minimap.lua:19>
[string "=[C]"]: ?

Locals: this = ExpansionLandingPageMinimapButton {
 0 = <userdata>
 OnLeave = <function> defined @Interface/FrameXML/Minimap.lua:761
 description = "Click to show the Dragon Isles Summary"
 UpdateIconForGarrison = <function> defined @Interface/FrameXML/Minimap.lua:902
 SideToastGlow = Texture {
 }
 defaultGlowWidth = 46
 ClearPulses = <function> defined @Interface/FrameXML/Minimap.lua:797
 OnClick = <function> defined @Interface/FrameXML/Minimap.lua:741
 ToggleLandingPage = <function> defined @Interface/FrameXML/Minimap.lua:745
 TriggerAlert = <function> defined @Interface/FrameXML/Minimap.lua:804
 OnShow = <function> defined @Interface/FrameXML/Minimap.lua:687
 LoopingGlow = Texture {
 }
 SetPulseLock = <function> defined @Interface/FrameXML/Minimap.lua:765
 pulseLocks = <table> {
 }
 HandleGarrisonEvent = <function> defined @Interface/FrameXML/Minimap.lua:859
 defaultHeight = 53
 MinimapLoopPulseAnim = AnimationGroup {
 }
 UpdateIcon = <function> defined @Interface/FrameXML/Minimap.lua:728
 garrisonMode = false
 defaultGlowHeight = 46
 HidePulse = <function> defined @Interface/FrameXML/Minimap.lua:781
 SoftButtonGlow = Texture {
 }
 AlertBG = Texture {
 }
 CircleGlow = Texture {
 }
 OnLoad = <function> defined @Interface/FrameXML/Minimap.lua:657
 OnHide = <function> defined @Interface/FrameXML/Minimap.lua:694
 title = "Dragon Isles Summary"
 OnEvent = <function> defined @Interface/FrameXML/Minimap.lua:702
 MinimapPulseAnim = AnimationGroup {
 }
 RefreshButton = <function> defined @Interface/FrameXML/Minimap.lua:670
 OnEnter = <function> defined @Interface/FrameXML/Minimap.lua:754
 MinimapAlertAnim = AnimationGroup {
 }
 defaultWidth = 53
 TriggerPulseLock = <function> defined @Interface/FrameXML/Minimap.lua:769
 AlertText = FontString {
 }
 JustifyText = <function> defined @Interface/FrameXML/Minimap.lua:810
}
button = "LeftButton"
(*temporary) = nil
(*temporary) = nil
(*temporary) = nil
(*temporary) = nil
(*temporary) = nil
(*temporary) = "attempt to index global 'GarrisonLandingPage' (a nil value)"

commented

You can add this section

        if not GarrisonLandingPage then
           return
        end

in minimap.lua after

    ExpansionLandingPageMinimapButton:HookScript("OnClick",
      function (this,button)

I don't know why but when this part is being called GarrisonLandingPage is not (yet?) set (or maybe not in scope)