Skip to content

Commit

Permalink
Fixes #82 - Put in check for empty continent
Browse files Browse the repository at this point in the history
  • Loading branch information
DanSheps committed Nov 6, 2018
1 parent c3b320e commit 1e4c746
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions BeStride_Logic.lua
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ function BeStride_Logic:IsSpecialZone()
local zone = BeStride:GetMapUntil(mapID,3)
local continent = BeStride:GetMapUntil(mapID,2)

if continent.name == BeStride_Locale.Continent.Draenor and micro.name == BeStride_Locale.Zone.Nagrand and self:DBGet("settings.mount.telaari") == true then
if continent ~= nil and continent.name == BeStride_Locale.Continent.Draenor and micro.name == BeStride_Locale.Zone.Nagrand and self:DBGet("settings.mount.telaari") == true then
local garrisonAbilityName = GetSpellInfo(161691)
local _,_,_,_,_,_,spellID = GetSpellInfo(garrisonAbilityName)
if(spellID == 165803 or spellID == 164222) then
Expand All @@ -576,7 +576,7 @@ function BeStride_Logic:SpecialZone()
local zone = BeStride:GetMapUntil(mapID,3)
local continent = BeStride:GetMapUntil(mapID,2)

if continent.name == BeStride_Locale.Continent.Draenor and micro.name == BeStride_Locale.Zone.Nagrand and self:DBGet("settings.mount.telaari") == true then
if continent ~= nil and continent.name == BeStride_Locale.Continent.Draenor and micro.name == BeStride_Locale.Zone.Nagrand and self:DBGet("settings.mount.telaari") == true then
return BeStride_Mount:Nagrand()
end

Expand Down

0 comments on commit 1e4c746

Please sign in to comment.