all: rename NetworkLock functions/types to TailnetLock
To avoid breaking downstream code, add deprecated aliases for all the old names. Updates tailscale/corp#37904 Change-Id: I86d0b0d7da371946440b181c665448f91c3ef8d2 Signed-off-by: Alex Chan <alexc@tailscale.com>
This commit is contained in:
@@ -41,8 +41,8 @@ func handleC2NDebugTKALog(b *ipnlocal.LocalBackend, w http.ResponseWriter, r *ht
|
||||
}
|
||||
}
|
||||
|
||||
updates, err := b.NetworkLockLog(limit)
|
||||
if ipnlocal.IsNetworkLockNotActive(err) {
|
||||
updates, err := b.TailnetLockLog(limit)
|
||||
if ipnlocal.IsTailnetLockNotActive(err) {
|
||||
http.Error(w, "tailnet lock not active", http.StatusBadRequest)
|
||||
return
|
||||
} else if err != nil {
|
||||
@@ -50,5 +50,5 @@ func handleC2NDebugTKALog(b *ipnlocal.LocalBackend, w http.ResponseWriter, r *ht
|
||||
return
|
||||
}
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
jsonoutput.PrintNetworkLockLogJSONV1(w, updates)
|
||||
jsonoutput.PrintTailnetLockLogJSONV1(w, updates)
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ func TestHandleC2NDebugTKA(t *testing.T) {
|
||||
return sb.String()
|
||||
}
|
||||
|
||||
// matches [jsonoutput.PrintNetworkLockLogJSONV1]
|
||||
// matches [jsonoutput.PrintTailnetLockLogJSONV1]
|
||||
type response struct {
|
||||
SchemaVersion string
|
||||
Messages []any
|
||||
|
||||
Reference in New Issue
Block a user