mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-12 02:54:20 +00:00
fix: use host with potential port for instance context (#7022)
This commit is contained in:
parent
a87f54b328
commit
6f3afb810d
@ -111,7 +111,7 @@ func hostFromOrigin(ctx context.Context) (host string, err error) {
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
host = u.Hostname()
|
||||
host = u.Host
|
||||
if host == "" {
|
||||
err = errors.New("empty host")
|
||||
}
|
||||
|
@ -221,7 +221,7 @@ func Test_setInstance(t *testing.T) {
|
||||
r.Header.Set("host", "fromrequest")
|
||||
return r.WithContext(zitadel_http.WithComposedOrigin(r.Context(), "https://fromorigin:9999"))
|
||||
}(),
|
||||
verifier: &mockInstanceVerifier{"fromorigin"},
|
||||
verifier: &mockInstanceVerifier{"fromorigin:9999"},
|
||||
headerName: "host",
|
||||
},
|
||||
res{
|
||||
|
Loading…
Reference in New Issue
Block a user