mirror of
https://github.com/simon-ding/polaris.git
synced 2026-06-09 11:39:46 +08:00
fix: db init
This commit is contained in:
1
db/db.go
1
db/db.go
@@ -42,6 +42,7 @@ func Open() (*Client, error) {
|
|||||||
c := &Client{
|
c := &Client{
|
||||||
ent: client,
|
ent: client,
|
||||||
}
|
}
|
||||||
|
c.init()
|
||||||
|
|
||||||
return c, nil
|
return c, nil
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ func HttpHandler(f func(*gin.Context) (interface{}, error)) gin.HandlerFunc {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
//log.Infof("url %v return: %+v", ctx.Request.URL, r)
|
log.Debug("url %v return: %+v", ctx.Request.URL, r)
|
||||||
|
|
||||||
ctx.JSON(200, Response{
|
ctx.JSON(200, Response{
|
||||||
Code: 0,
|
Code: 0,
|
||||||
|
|||||||
Reference in New Issue
Block a user