Improved APKPure compatibility by prioritizing APK when available (over XAPK)

This commit is contained in:
Imran Remtulla
2024-09-05 13:10:02 -04:00
parent 151e085655
commit e019c8027b

View File

@@ -109,11 +109,16 @@ class APKPure extends AppSource {
'') '')
?.group(0) ?.group(0)
?.trim(); ?.trim();
String? type = apkInfo var types = apkInfo
?.querySelector('div.info-top span.tag') ?.querySelectorAll('div.info-top span.tag')
?.text .map((e) => e.text.trim())
.trim() ?? .map((t) => t == 'APKs' ? 'APK' : t) ??
'APK'; [];
String type = types.length == 0
? 'APK'
: types.length == 1
? types.first
: types.last;
String? dateString = apkInfo String? dateString = apkInfo
?.querySelector('div.info-bottom span.time') ?.querySelector('div.info-bottom span.time')
?.text ?.text