Merge pull request #1 from phillmv/fix-verify-api-requests
Fix: the wrong hostname was being passed in to the API client
This commit is contained in:
commit
64c3fd02aa
1 changed files with 1 additions and 3 deletions
|
|
@ -7,7 +7,6 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/cli/cli/v2/api"
|
||||
"github.com/cli/cli/v2/internal/ghinstance"
|
||||
ioconfig "github.com/cli/cli/v2/pkg/cmd/attestation/io"
|
||||
"github.com/cli/go-gh/v2/pkg/auth"
|
||||
)
|
||||
|
|
@ -35,11 +34,10 @@ type LiveClient struct {
|
|||
|
||||
func NewLiveClient(hc *http.Client, l *ioconfig.Handler) *LiveClient {
|
||||
host, _ := auth.DefaultHost()
|
||||
serverURL := ghinstance.HostPrefix(host)
|
||||
|
||||
return &LiveClient{
|
||||
api: api.NewClientFromHTTP(hc),
|
||||
host: strings.TrimSuffix(serverURL, "/"),
|
||||
host: strings.TrimSuffix(host, "/"),
|
||||
logger: l,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue