diff options
-rw-r--r-- | init.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/init.go b/init.go index 639a78b..97a998c 100644 --- a/init.go +++ b/init.go @@ -214,7 +214,9 @@ func initTemplates() *template.Template { // Pull DB data into cache, if available. func initDatabase() { + confObj.mu.RLock() db, err := leveldb.OpenFile(confObj.dbPath, nil) + confObj.mu.RUnlock() if err != nil { log.Fatalf("%v\n", err) } |