File tree 1 file changed +12
-0
lines changed
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,8 @@ import 'package:html/parser.dart';
5
5
import 'package:http/http.dart' ;
6
6
import 'package:obtainium/components/generated_form.dart' ;
7
7
import 'package:obtainium/custom_errors.dart' ;
8
+ import 'package:obtainium/providers/apps_provider.dart' ;
9
+ import 'package:obtainium/providers/settings_provider.dart' ;
8
10
import 'package:obtainium/providers/source_provider.dart' ;
9
11
10
12
class APKMirror extends AppSource {
@@ -31,6 +33,16 @@ class APKMirror extends AppSource {
31
33
];
32
34
}
33
35
36
+ @override
37
+ Future <Map <String , String >?> getRequestHeaders (
38
+ Map <String , dynamic > additionalSettings,
39
+ {bool forAPKDownload = false }) async {
40
+ return {
41
+ "User-Agent" :
42
+ "Obtainium/${(await getInstalledInfo (obtainiumId ))?.versionName ?? '1.0.0' }"
43
+ };
44
+ }
45
+
34
46
@override
35
47
String sourceSpecificStandardizeURL (String url, {bool forSelection = false }) {
36
48
RegExp standardUrlRegEx = RegExp (
You can’t perform that action at this time.
0 commit comments