MCPcopy
hub / github.com/wavetermdev/waveterm / SetAsRootRouter

Method SetAsRootRouter

pkg/wshutil/wshrouter.go:179–190  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

177}
178
179func (router *WshRouter) SetAsRootRouter() {
180 router.lock.Lock()
181 defer router.lock.Unlock()
182 router.isRootRouter = true
183
184 // also bind $control:root to the control RPC
185 linkId := router.routeMap[ControlRoute]
186 if linkId != baseds.NoLinkId {
187 router.routeMap[ControlRootRoute] = linkId
188 log.Printf("wshrouter registered control:root route linkid=%d", linkId)
189 }
190}
191
192func noRouteErr(routeId string) error {
193 if routeId == "" {

Callers 2

mainFunction · 0.80
initTestHarnessFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected