mirror of
https://github.com/nezhahq/nezha.git
synced 2025-01-22 12:48:14 -05:00
fix config default value (#538)
* fix config & state fields * revert state
This commit is contained in:
parent
07a942e234
commit
91a7c934e6
@ -89,6 +89,9 @@ func (c *Config) Read(path string) error {
|
||||
if c.AvgPingCount == 0 {
|
||||
c.AvgPingCount = 2
|
||||
}
|
||||
if c.Cover == 0 {
|
||||
c.Cover = 1
|
||||
}
|
||||
if c.JWTSecretKey == "" {
|
||||
c.JWTSecretKey, err = utils.GenerateRandomString(1024)
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user