mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-30 15:05:27 +00:00
Watch handler not returning after 404
This commit is contained in:
parent
c71866164f
commit
d419eedb06
@ -55,10 +55,12 @@ func (h *WatchHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) {
|
||||
parts := splitPath(req.URL.Path)
|
||||
if len(parts) < 1 || req.Method != "GET" {
|
||||
notFound(w, req)
|
||||
return
|
||||
}
|
||||
storage := h.storage[parts[0]]
|
||||
if storage == nil {
|
||||
notFound(w, req)
|
||||
return
|
||||
}
|
||||
if watcher, ok := storage.(ResourceWatcher); ok {
|
||||
label, field, resourceVersion := getWatchParams(req.URL.Query())
|
||||
|
Loading…
Reference in New Issue
Block a user