This commit is contained in:
Liang Ding 2019-05-23 18:42:59 +08:00
parent 1857df995d
commit 38f88c2c17
No known key found for this signature in database
GPG Key ID: 136F30F901A2231D
1 changed files with 4 additions and 1 deletions

View File

@ -64,6 +64,7 @@ type conf struct {
HTTPSessionMaxAge int // HTTP session max age (in seciond) HTTPSessionMaxAge int // HTTP session max age (in seciond)
StaticResourceVersion string // version of static resources StaticResourceVersion string // version of static resources
Locale string // default locale Locale string // default locale
Autocomplete bool // default autocomplete
SiteStatCode template.HTML // site statistic code SiteStatCode template.HTML // site statistic code
} }
@ -175,6 +176,8 @@ func initWide(confPath, confData, confServer, confLogLevel string, confSiteStatC
os.Exit(-1) os.Exit(-1)
} }
Wide.Autocomplete = true // default to true
// Logging Level // Logging Level
log.SetLevel(Wide.LogLevel) log.SetLevel(Wide.LogLevel)
if "" != confLogLevel { if "" != confLogLevel {
@ -238,7 +241,7 @@ func FixedTimeCheckEnv() {
checkEnv() // check immediately checkEnv() // check immediately
go func() { go func() {
for _ = range time.Tick(time.Minute*7) { for _ = range time.Tick(time.Minute * 7) {
checkEnv() checkEnv()
} }
}() }()