Don't crash when attempting to launch an app that has been uninstalled
This commit is contained in:
parent
97ba10d3a7
commit
701ab490d2
@ -1,5 +1,6 @@
|
||||
package de.mm20.launcher2.search.data
|
||||
|
||||
import android.content.ActivityNotFoundException
|
||||
import android.content.ComponentName
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
@ -115,6 +116,8 @@ class LauncherApp(
|
||||
)
|
||||
} catch (e: SecurityException) {
|
||||
return false
|
||||
} catch (e: ActivityNotFoundException) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
return true
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user