mirror of
https://github.com/f-droid/fdroidclient.git
synced 2026-04-19 06:23:07 -04:00
Use ServiceCompat.stopForeground().
This commit is contained in:
@@ -21,6 +21,7 @@ import android.util.Log;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.core.app.NotificationCompat;
|
||||
import androidx.core.app.ServiceCompat;
|
||||
import androidx.core.content.ContextCompat;
|
||||
import androidx.localbroadcastmanager.content.LocalBroadcastManager;
|
||||
|
||||
@@ -452,7 +453,7 @@ public class SwapService extends Service {
|
||||
if (timer != null) {
|
||||
timer.cancel();
|
||||
}
|
||||
stopForeground(true);
|
||||
ServiceCompat.stopForeground(this, ServiceCompat.STOP_FOREGROUND_REMOVE);
|
||||
|
||||
deleteAllSwapRepos();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user