mirror of
https://github.com/tailscale/tailscale.git
synced 2025-03-24 10:10:59 +00:00
ipn/ipnlocal: inline assertClientLocked into its now sole caller
Updates #11649 Change-Id: I8e2a5e59125a0cad5c0a8c9ed8930585f1735d03 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
parent
170c618483
commit
970b1e21d0
@ -2839,7 +2839,9 @@ func (b *LocalBackend) tryLookupUserName(uid string) string {
|
||||
// up the in-progress flow where it left off.
|
||||
func (b *LocalBackend) StartLoginInteractive() {
|
||||
b.mu.Lock()
|
||||
b.assertClientLocked()
|
||||
if b.cc == nil {
|
||||
panic("LocalBackend.assertClient: b.cc == nil")
|
||||
}
|
||||
b.interact = true
|
||||
url := b.authURL
|
||||
timeSinceAuthURLCreated := b.clock.Since(b.authURLTime)
|
||||
@ -4729,13 +4731,6 @@ func (b *LocalBackend) Logout(ctx context.Context) error {
|
||||
return b.resetForProfileChangeLockedOnEntry(unlock)
|
||||
}
|
||||
|
||||
// assertClientLocked crashes if there is no controlclient in this backend.
|
||||
func (b *LocalBackend) assertClientLocked() {
|
||||
if b.cc == nil {
|
||||
panic("LocalBackend.assertClient: b.cc == nil")
|
||||
}
|
||||
}
|
||||
|
||||
// setNetInfo sets b.hostinfo.NetInfo to ni, and passes ni along to the
|
||||
// controlclient, if one exists.
|
||||
func (b *LocalBackend) setNetInfo(ni *tailcfg.NetInfo) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user