Commit 9c7d95b0 authored by ysqi's avatar ysqi

go vet

parent b2a06c5f
...@@ -122,12 +122,11 @@ type ConfigContainer struct { ...@@ -122,12 +122,11 @@ type ConfigContainer struct {
// Bool returns the boolean value for a given key. // Bool returns the boolean value for a given key.
func (c *ConfigContainer) Bool(key string) (bool, error) { func (c *ConfigContainer) Bool(key string) (bool, error) {
v, err := c.getData(key)
if v, err := c.getData(key); err != nil { if err != nil {
return false, err return false, err
} else {
return config.ParseBool(v)
} }
return config.ParseBool(v)
} }
// DefaultBool return the bool value if has no error // DefaultBool return the bool value if has no error
......
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 to comment