mirror of
https://github.com/tailscale/tailscale.git
synced 2026-11-28 20:46:28 -08:00
internal/client/tailscale: change Client from alias into wrapper
This will allow Client to be extended with additional functions for internal use. Updates tailscale/corp#22748 Signed-off-by: Percy Wegmann <[email protected]>
This commit is contained in:
1 parent
8a792ab540
commit
9ae9de469a
1 file changed
+8
-4
@@ -15,9 +15,6 @@ func init() {
|
||||
tsclient.I_Acknowledge_This_API_Is_Unstable = true
|
||||
}
|
||||
|
||||
// Client is an alias to tailscale.com/client/tailscale.
|
||||
type Client = tsclient.Client
|
||||
|
||||
// AuthMethod is an alias to tailscale.com/client/tailscale.
|
||||
type AuthMethod = tsclient.AuthMethod
|
||||
|
||||
@@ -44,5 +41,12 @@ type ErrResponse = tsclient.ErrResponse
|
||||
|
||||
// NewClient is an alias to tailscale.com/client/tailscale.
|
||||
func NewClient(tailnet string, auth AuthMethod) *Client {
|
||||
return tsclient.NewClient(tailnet, auth)
|
||||
return &Client{
|
||||
Client: tsclient.NewClient(tailnet, auth),
|
||||
}
|
||||
}
|
||||
|
||||
// Client is a wrapper of tailscale.com/client/tailscale.
|
||||
type Client struct {
|
||||
*tsclient.Client
|
||||
}
|
||||
Reference in new issue
Block a user