Skip to content
Snippets Groups Projects
Commit 8b5d88d1 authored by akwizgran's avatar akwizgran
Browse files

Remove message notifications when shutting down.

parent f17a7608
No related branches found
No related tags found
No related merge requests found
......@@ -136,6 +136,10 @@ public class BriarService extends RoboService implements EventListener {
public void onDestroy() {
super.onDestroy();
if(LOG.isLoggable(INFO)) LOG.info("Destroyed");
Object o = getSystemService(NOTIFICATION_SERVICE);
NotificationManager nm = (NotificationManager) o;
nm.cancel(PRIVATE_MESSAGE_NOTIFICATION_ID);
nm.cancel(GROUP_POST_NOTIFICATION_ID);
stopForeground(true);
// Stop the services in a background thread
new Thread() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment