mirror of
https://github.com/ReVanced/revanced-manager.git
synced 2024-11-10 01:01:56 +01:00
fix: Surround isRooted with a try/catch just to be safe
This commit is contained in:
parent
31756884b6
commit
ef0c59f693
1 changed files with 6 additions and 2 deletions
|
@ -6,8 +6,12 @@ class RootAPI {
|
|||
final String _serviceDDirPath = '/data/adb/service.d';
|
||||
|
||||
Future<bool> hasRootPermissions() async {
|
||||
bool? isRooted = await Root.isRooted();
|
||||
return isRooted != null && isRooted;
|
||||
try {
|
||||
bool? isRooted = await Root.isRooted();
|
||||
return isRooted != null && isRooted;
|
||||
} on Exception {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> setPermissions(
|
||||
|
|
Loading…
Reference in a new issue