mirror of
https://github.com/fatedier/frp.git
synced 2025-07-26 23:29:58 +00:00
optimize some code (#3801)
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
"strings"
|
||||
|
||||
"github.com/fatedier/frp/client"
|
||||
"github.com/fatedier/frp/pkg/util/util"
|
||||
httppkg "github.com/fatedier/frp/pkg/util/http"
|
||||
)
|
||||
|
||||
type Client struct {
|
||||
@@ -115,7 +115,7 @@ func (c *Client) UpdateConfig(content string) error {
|
||||
|
||||
func (c *Client) setAuthHeader(req *http.Request) {
|
||||
if c.authUser != "" || c.authPwd != "" {
|
||||
req.Header.Set("Authorization", util.BasicAuth(c.authUser, c.authPwd))
|
||||
req.Header.Set("Authorization", httppkg.BasicAuth(c.authUser, c.authPwd))
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user