ipn/ipnlocal: use ipn.PrefsView

Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
Maisem Ali
2022-10-23 17:07:10 +00:00
committed by Maisem Ali
parent 20324eeebc
commit 0957bc5af2
11 changed files with 181 additions and 184 deletions
+2 -2
View File
@@ -22,7 +22,7 @@ func (b *FakeBackend) Start(opts Options) error {
}
nl := NeedsLogin
if b.notify != nil {
b.notify(Notify{Prefs: opts.Prefs})
b.notify(Notify{Prefs: opts.Prefs.View()})
b.notify(Notify{State: &nl})
}
return nil
@@ -83,7 +83,7 @@ func (b *FakeBackend) SetPrefs(new *Prefs) {
}
if b.notify != nil {
b.notify(Notify{Prefs: new.Clone()})
b.notify(Notify{Prefs: new.View()})
}
if new.WantRunning && !b.live {
b.newState(Starting)