Skip to content

Commit

Permalink
feat: Include primary architecture in external search (#2068)
Browse files Browse the repository at this point in the history
  • Loading branch information
validcube authored Jul 29, 2024
1 parent 7449d4e commit 23690a9
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions lib/ui/views/app_selector/app_selector_viewmodel.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import 'package:revanced_manager/services/manager_api.dart';
import 'package:revanced_manager/services/patcher_api.dart';
import 'package:revanced_manager/services/toast.dart';
import 'package:revanced_manager/ui/views/patcher/patcher_viewmodel.dart';
import 'package:revanced_manager/utils/about_info.dart';
import 'package:revanced_manager/utils/check_for_supported_patch.dart';
import 'package:stacked/stacked.dart';

Expand Down Expand Up @@ -74,11 +75,14 @@ class AppSelectorViewModel extends BaseViewModel {
required String packageName,
}) async {
final String suggestedVersion = getSuggestedVersion(packageName);
final String architecture = await AboutInfo.getInfo().then((info) {
return info['supportedArch'][0];
});

if (suggestedVersion.isNotEmpty) {
await openDefaultBrowser('$packageName apk version $suggestedVersion');
await openDefaultBrowser('$packageName apk version $suggestedVersion $architecture');
} else {
await openDefaultBrowser('$packageName apk');
await openDefaultBrowser('$packageName apk $architecture');
}
}

Expand Down Expand Up @@ -178,7 +182,6 @@ class AppSelectorViewModel extends BaseViewModel {
fontSize: 16,
fontWeight: FontWeight.w500,
),

),
actions: [
FilledButton(
Expand Down

0 comments on commit 23690a9

Please sign in to comment.