Skip to content

Commit

Permalink
Watch handler not returning after 404
Browse files Browse the repository at this point in the history
  • Loading branch information
smarterclayton committed Aug 9, 2014
1 parent c718661 commit d419eed
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/apiserver/watch.go
Original file line number Diff line number Diff line change
Expand Up @@ -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())
Expand Down

0 comments on commit d419eed

Please sign in to comment.