You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't know where dose the variable api come from?
funcMyMiddleware(ctx huma.Context, nextfunc(ctx huma.Context)) {
// If there is a query parameter "error=true", then return an errorifctx.Query("error") =="true" {
// WHERE DOSE THE VARIABLE API COME FROMhuma.WriteErr(api, ctx, http.StatusInternalServerError,
"Some friendly message", fmt.Errorf("error detail"),
)
return
}
// Otherwise, just continue as normal.next(ctx)
})
The text was updated successfully, but these errors were encountered:
In huma middleware docs.
I don't know where dose the variable
api
come from?The text was updated successfully, but these errors were encountered: