mirror of
https://github.com/brues-code/SuperCleveRoidMacros.git
synced 2026-09-16 03:38:00 +00:00
Fix addon initialization order with guard checks
Refactor mouseover extensions to split initialization into two phases: OnLoad (empty) and OnAddOnLoad (actual setup). This ensures hooks are only registered when the target addon's globals are defined. Add guard clauses to check for required functions before hooking. Also remove Cursive's premature initialization attempt.
This commit is contained in:
@@ -74,9 +74,4 @@ function Extension.OnLoad()
|
||||
end)
|
||||
end
|
||||
|
||||
-- Also try to hook immediately in case Cursive is already loaded
|
||||
if Cursive and Cursive.ui then
|
||||
HookCursiveUI()
|
||||
end
|
||||
|
||||
EventUtil.ContinueOnAddOnLoaded("Cursive", Extension.OnLoad)
|
||||
|
||||
Reference in New Issue
Block a user