mirror of
https://github.com/foss42/apidash.git
synced 2025-12-10 07:08:08 +08:00
Merge branch 'main' of https://github.com/foss42/apidash
This commit is contained in:
@@ -29,6 +29,10 @@ String stripUrlParams(String url) {
|
||||
if (url == null || url == "") {
|
||||
return (null, "URL is missing!");
|
||||
}
|
||||
|
||||
if (kLocalhostRegex.hasMatch(url)) {
|
||||
url = '${SupportedUriSchemes.http.name}://$url';
|
||||
}
|
||||
Uri? uri = Uri.tryParse(url);
|
||||
if (uri == null) {
|
||||
return (null, "Check URL (malformed)");
|
||||
|
||||
Reference in New Issue
Block a user