code: func (m *PathRecorderMux) refreshMuxLocked() {
  	newMux := &pathHandler{
  		muxName:         m.name,
  		pathToHandler:   map[string]http.Handler{},
  		prefixHandlers:  []prefixHandler{},
  		notFoundHandler: http.NotFoundHandler(),
  	}
  	if m.notFoundHandler != nil {
  		newMux.notFoundHandler = m.notFoundHandler
  	}
  	for path, handler := range m.pathToHandler {
  		newMux.pathToHandler[path] = handler
  	}
  
  	keys := sets.StringKeySet(m.prefixToHandler).List()
  	sort.Sort(sort.Reverse(byPrefixPriority(keys)))
  	for _, prefix := range keys {
  		newMux.prefixHandlers = append(newMux.prefixHandlers, prefixHandler{
  			prefix:  prefix,
  			handler: m.prefixToHandler[prefix],
  		})
  	}
  
  	m.mux.Store(newMux)
  }
docs: // refreshMuxLocked creates a new mux and must be called while locked.  Otherwise the view of handlers may
  // not be consistent