fix: organization 404 write 1 http status (#13629)

This commit is contained in:
Steven Masley
2024-06-21 08:01:46 -10:00
committed by GitHub
parent 0e933f0537
commit 5177f366f5

View File

@ -78,10 +78,6 @@ func ExtractOrganizationParam(db database.Store) func(http.Handler) http.Handler
}
if httpapi.Is404Error(dbErr) {
httpapi.ResourceNotFound(rw)
httpapi.Write(ctx, rw, http.StatusNotFound, codersdk.Response{
Message: fmt.Sprintf("Organization %q not found.", arg),
Detail: "Provide either the organization id or name.",
})
return
}
if dbErr != nil {