Skip to content

Commit

Permalink
Fix empty response in admin/get-parent-entries handler.
Browse files Browse the repository at this point in the history
  • Loading branch information
knadh committed Jun 26, 2022
1 parent 30e27f5 commit b1dd443
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/dictpress/admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,10 @@ func handleGetParentEntries(c echo.Context) error {
return echo.NewHTTPError(http.StatusInternalServerError, err.Error())
}

if out == nil {
out = []data.Entry{}
}

return c.JSON(http.StatusOK, okResp{out})
}

Expand Down

0 comments on commit b1dd443

Please sign in to comment.