10 lines
224 B
Go
10 lines
224 B
Go
package drip
|
|
|
|
import "net/http"
|
|
|
|
type ErrorHandler func(err error, ctx *Context)
|
|
|
|
func defaultErrorHandler(err error, c *Context) {
|
|
c.JSON(http.StatusInternalServerError, Json{"status": "failed", "message": err.Error()})
|
|
}
|