API Frame UnregisterAllEvents
From WoWWiki
Unregisters all events that the object is currently monitoring.
obj:UnregisterAllEvents();
Example
myChatAddon:UnregisterAllEvents();
Result
Code in the <OnEvent> section of your addon would no longer fire.
Unregisters all events that the object is currently monitoring.
obj:UnregisterAllEvents();
myChatAddon:UnregisterAllEvents();
Code in the <OnEvent> section of your addon would no longer fire.