This commit is contained in:
deepzz0 committed 2016-12-24 12:34:27 +08:00
1 parent 26e2440666
commit 45e3c4f0c9
1 file changed
+3 -1
+3 -1
View File
@@ -28,7 +28,9 @@ var es *ElasticService
func init() { func init() {
es = &ElasticService{url: setting.Conf.SearchURL, c: new(http.Client)} es = &ElasticService{url: setting.Conf.SearchURL, c: new(http.Client)}
initIndex() if setting.Conf.RunMode == setting.PROD {
initIndex()
}
} }
func initIndex() { func initIndex() {