summaryrefslogtreecommitdiff
path: root/pkg/api/handlers/images.go
diff options
context:
space:
mode:
authorBrent Baude <bbaude@redhat.com>2020-02-20 10:41:28 -0600
committerBrent Baude <bbaude@redhat.com>2020-02-21 12:53:39 -0600
commitea153c8e2eb2e371a7e7f5825ab65f0abd5a580d (patch)
treeed84e4234111e388a9e356505c89adbeecd99ec8 /pkg/api/handlers/images.go
parent75ea3b67c6a5c3b6a3e4b7f5ae173c09c8e9c2d5 (diff)
downloadpodman-ea153c8e2eb2e371a7e7f5825ab65f0abd5a580d.tar.gz
podman-ea153c8e2eb2e371a7e7f5825ab65f0abd5a580d.tar.bz2
podman-ea153c8e2eb2e371a7e7f5825ab65f0abd5a580d.zip
search endpoint failure correction
when returning an invalid search, a return was omitted triggering a null on the consumer end. Fixes: #5228 Signed-off-by: Brent Baude <bbaude@redhat.com>
Diffstat (limited to 'pkg/api/handlers/images.go')
-rw-r--r--pkg/api/handlers/images.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/pkg/api/handlers/images.go b/pkg/api/handlers/images.go
index e4e394d68..96bcbdc96 100644
--- a/pkg/api/handlers/images.go
+++ b/pkg/api/handlers/images.go
@@ -156,6 +156,7 @@ func SearchImages(w http.ResponseWriter, r *http.Request) {
results, err := image.SearchImages(query.Term, options)
if err != nil {
utils.BadRequest(w, "term", query.Term, err)
+ return
}
utils.WriteResponse(w, http.StatusOK, results)
}