Prevent crash

This commit is contained in:
M66B
2021-03-24 18:55:18 +01:00
parent d0615fd488
commit e322d4f8bc
2 changed files with 10 additions and 3 deletions

View File

@@ -753,8 +753,11 @@ public class ServiceSend extends ServiceBase implements SharedPreferences.OnShar
}
static void start(Context context) {
ContextCompat.startForegroundService(context,
new Intent(context, ServiceSend.class));
try {
ContextCompat.startForegroundService(context, new Intent(context, ServiceSend.class));
} catch (Throwable ex) {
Log.e(ex);
}
}
static void schedule(Context context, long delay) {