We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 878d633 commit 5c840fdCopy full SHA for 5c840fd
coderd/users.go
@@ -122,6 +122,10 @@ func (api *api) users(rw http.ResponseWriter, r *http.Request) {
122
Search: searchName,
123
Status: statusFilter,
124
})
125
+ if errors.Is(err, sql.ErrNoRows) {
126
+ httpapi.Write(rw, http.StatusOK, []codersdk.User{})
127
+ return
128
+ }
129
if err != nil {
130
httpapi.Write(rw, http.StatusInternalServerError, httpapi.Response{
131
Message: err.Error(),
0 commit comments