Skip to content

Commit

Permalink
Merge pull request #606 from ShotaKitazawa/fix
Browse files Browse the repository at this point in the history
fix URL construction
  • Loading branch information
ShotaKitazawa authored Jul 15, 2024
2 parents bf5e073 + d75ece9 commit 1c128d7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions server/view/json.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,10 @@ func (v JSON) ListIngressInfo(ctx echo.Context, list []models.IngressInfo) error

var res []IngressInfo
for _, val := range list {
u, err := url.Parse(val.Proto + "://" + val.Hostname + "/" + val.Path)
if err != nil {
return err
u := &url.URL{
Scheme: val.Proto,
Host: val.Hostname,
Path: val.Path,
}
res = append(res, IngressInfo{
Name: val.Name,
Expand Down

0 comments on commit 1c128d7

Please sign in to comment.