mirror of
https://github.com/vlang/v.git
synced 2025-09-13 14:32:26 +03:00
url: fix parse (#14456)
This commit is contained in:
parent
95d24e543d
commit
23568f19da
2 changed files with 22 additions and 1 deletions
|
@ -599,7 +599,7 @@ fn parse_host(host string) ?string {
|
|||
return host1 + host2 + host3
|
||||
}
|
||||
if idx := host.last_index(':') {
|
||||
colon_port = host[idx..]
|
||||
colon_port = host[idx..i]
|
||||
if !valid_optional_port(colon_port) {
|
||||
return error(error_msg('parse_host: invalid port $colon_port after host ',
|
||||
''))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue