diff --git a/src/main.cpp b/src/main.cpp index 3cdcdb9..f383403 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -68,6 +68,13 @@ INITIALIZE_PLUGIN() { deinitLogging(); } +DEINITIALIZE_PLUGIN() { + if (gNotificationModuleInitDone) { + NotificationModule_DeInitLibrary(); + gNotificationModuleInitDone = false; + } +} + // Called whenever an application was started. ON_APPLICATION_START() { initLogging(); @@ -89,10 +96,3 @@ ON_APPLICATION_REQUESTS_EXIT() { } deinitLogging(); } - -ON_APPLICATION_ENDS() { - if (gNotificationModuleInitDone) { - NotificationModule_DeInitLibrary(); - gNotificationModuleInitDone = false; - } -} \ No newline at end of file