MCPcopy Index your code
hub / github.com/LumaAI-API/Luma-API / WrapperLumaError

Function WrapperLumaError

luma.go:36–44  ·  view source on GitHub ↗
(c *gin.Context, err error, statusCode int)

Source from the content-addressed store, hash-verified

34}
35
36func WrapperLumaError(c *gin.Context, err error, statusCode int) {
37 common.Logger.Errorw("wrapper luma error", "statusCode", statusCode, "err", err)
38 c.JSON(statusCode, gin.H{
39 "detail": map[string]any{
40 "reason": err.Error(),
41 "code": 1,
42 },
43 })
44}
45
46func GenLumaError(err error, statusCode int) *WrapperErrorResp {
47 return &WrapperErrorResp{

Callers 6

FetchByIDFunction · 0.85
UploadFunction · 0.85
GetDownloadUrlFunction · 0.85
MeFunction · 0.85
UsageFunction · 0.85
doGenerationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected