You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
307 B
20 lines
307 B
package lancermonitor |
|
|
|
import ( |
|
"errors" |
|
) |
|
|
|
type Config struct { |
|
Addr string `toml:"addr"` |
|
} |
|
|
|
func (c *Config) ConfigValidate() (error) { |
|
if c == nil { |
|
return errors.New("config of LancerMonitor is nil") |
|
} |
|
|
|
if c.Addr == "" { |
|
return errors.New("addr of LancerMonitor can't be nil") |
|
} |
|
return nil |
|
}
|
|
|