Fix broken "Download Asset" function for HTML source (#1998)

This commit is contained in:
Imran Remtulla
2024-12-08 13:47:32 -05:00
parent 5b79f399d1
commit 619d4f1a51
2 changed files with 7 additions and 2 deletions

View File

@@ -353,7 +353,12 @@ class HTML extends AppSource {
forAPKDownload: true),
allowInsecure: additionalSettings['allowInsecure'] == true))
.toString();
return APKDetails(version, [rel].map((e) => MapEntry(e, e)).toList(),
return APKDetails(
version,
[rel]
.map((e) =>
MapEntry('${e.hashCode}-${Uri.parse(e).pathSegments.last}', e))
.toList(),
AppNames(uri.host, tr('app')));
}
}

View File

@@ -240,7 +240,7 @@ class App {
late String name;
String? installedVersion;
late String latestVersion;
List<MapEntry<String, String>> apkUrls = [];
List<MapEntry<String, String>> apkUrls = []; // Key is name, value is URL
List<MapEntry<String, String>> otherAssetUrls = [];
late int preferredApkIndex;
late Map<String, dynamic> additionalSettings;