mirror of
https://github.com/ImranR98/Obtainium.git
synced 2025-07-30 12:30:16 +02:00
Fix missing trailing slash for path-less URLs (#1715)
This commit is contained in:
@@ -355,8 +355,10 @@ preStandardizeUrl(String url) {
|
||||
url = 'https://$url';
|
||||
}
|
||||
var uri = Uri.tryParse(url);
|
||||
var trailingSlash = (uri?.path.endsWith('/') ?? false) &&
|
||||
var trailingSlash = ((uri?.path.endsWith('/') ?? false) ||
|
||||
((uri?.path.isEmpty ?? false) && url.endsWith('/'))) &&
|
||||
(uri?.queryParameters.isEmpty ?? false);
|
||||
|
||||
url = url
|
||||
.split('/')
|
||||
.where((e) => e.isNotEmpty)
|
||||
|
Reference in New Issue
Block a user