Add missing return

libpod df handler missing a return after writing error to client. This
caused a null to be appended to JSON and crashed python decoder.

Signed-off-by: Jhon Honce <jhonce@redhat.com>
This commit is contained in:
Jhon Honce
2021-04-07 13:55:03 -07:00
parent 8c0df1c44a
commit 6cc0dc44ec
2 changed files with 5 additions and 0 deletions

View File

@ -72,6 +72,7 @@ func DiskUsage(w http.ResponseWriter, r *http.Request) {
response, err := ic.SystemDf(r.Context(), options)
if err != nil {
utils.InternalServerError(w, err)
return
}
utils.WriteResponse(w, http.StatusOK, response)
}