fixed default history limit count error

The default history limit count will be 0 if cfg not set.
Which will make history lose efficacy.
This commit is contained in:
招牌疯子 2015-10-08 17:43:22 +08:00
parent 7638a04c39
commit 492f37d9d4
1 changed files with 1 additions and 1 deletions

View File

@ -40,7 +40,7 @@ func (c *Config) Init() error {
if c.Stderr == nil {
c.Stderr = Stderr
}
if c.HistoryLimit < 0 {
if c.HistoryLimit <= 0 {
c.HistoryLimit = 500
}
return nil