refactor: error return

pull/458/head
Gordon 2 years ago
parent ba56e1e965
commit 475fff875a

@ -46,9 +46,8 @@ func startPprof() {
func run(port int) error {
if port == 0 {
port = config.Config.Api.GinPort[0]
return fmt.Errorf("port is empty")
}
var err error
rdb, err := cache.NewRedis()
if err != nil {
return err

Loading…
Cancel
Save