Register
UgHookName
required
A value of
UgCore.Enums.Hooks, such as 'Accounts:BeforeRemove'.fun(payload): boolean | table | nil
required
Return
false to cancel. Return a table to replace the payload for the next handlers. Return nothing to let it pass.integer
Lower runs first. Defaults to
0.integer
Pass to
Unregister.Unregister
Example
Your handler gets a copy of the payload. Return the changed table so ug-core sees your changes.