Commit ce120e9d by 孙龙

up

parent 960d23d3
Showing with 3 additions and 0 deletions
package db package db
import ( import (
"fmt"
_ "github.com/go-sql-driver/mysql" _ "github.com/go-sql-driver/mysql"
"github.com/jmoiron/sqlx" "github.com/jmoiron/sqlx"
) )
...@@ -34,6 +35,7 @@ func InitLabelDB(dns string) error{ ...@@ -34,6 +35,7 @@ func InitLabelDB(dns string) error{
} }
err = LabelDB.Ping() err = LabelDB.Ping()
fmt.Println(err)
if err != nil { if err != nil {
return err return err
} }
...@@ -49,6 +51,7 @@ func InitCmslDB(dns string) error{ ...@@ -49,6 +51,7 @@ func InitCmslDB(dns string) error{
} }
err = CmsDB.Ping() err = CmsDB.Ping()
fmt.Println(err)
if err != nil { if err != nil {
return err return err
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment