Fix 10.1.5 error building a player menu

This commit is contained in:
Parnic
2023-07-16 22:14:23 -10:00
parent 8bc7b1ee90
commit d9cfb3a09c
3 changed files with 15 additions and 5 deletions

View File

@ -886,11 +886,13 @@ local function munge_unit_menu(menu)
if btns[i].IsMenu() then
local subbtns = btns[i].GetMenuButtons()
for j=1, #subbtns do
local blacklisted = BLACKLISTED_UNIT_MENU_OPTIONS[subbtns[j]:GetText()]
if not blacklisted then
new_buttons_list[#new_buttons_list+1] = subbtns[j]
elseif blacklisted ~= true then
new_buttons_list[#new_buttons_list+1] = blacklisted
if subbtns[j] then
local blacklisted = BLACKLISTED_UNIT_MENU_OPTIONS[subbtns[j]:GetText()]
if not blacklisted then
new_buttons_list[#new_buttons_list+1] = subbtns[j]
elseif blacklisted ~= true then
new_buttons_list[#new_buttons_list+1] = blacklisted
end
end
end
else

View File

@ -1,5 +1,9 @@
# Changelog
v1.14.24:
- Fixed an error when targeting a player and right-clicking a module that should show a menu in 10.1.5.
v1.14.23:
- Update Dragonflight TOC for 10.1.5

View File

@ -1,5 +1,9 @@
# Changelog
v1.14.24:
- Fixed an error when targeting a player and right-clicking a module that should show a menu in 10.1.5.
v1.14.23:
- Update Dragonflight TOC for 10.1.5