diff --git a/app.go b/app.go index ed0c647..cbe9ed0 100644 --- a/app.go +++ b/app.go @@ -69,9 +69,9 @@ func (this *app) init(userApp UserApp) { _dbFilter = new(dbFilter) _dbFilter.init() _goStyleDb = new(dbPool) - _goStyleDb.init() + _goStyleDb.init(GO_STYLE_DB) _jsStyleDb = new(dbPool) - _jsStyleDb.init() + _jsStyleDb.init(JS_STYLE_DB) _httpCliMgr = new(HttpCliMgr) _httpCliMgr.init() { diff --git a/dbpool.go b/dbpool.go index 6e3cbd0..65e7951 100644 --- a/dbpool.go +++ b/dbpool.go @@ -29,7 +29,8 @@ type dbPool struct { dataSourceHash map[string]*q5.ListHead } -func (this *dbPool) init() { +func (this *dbPool) init(style DBStyle) { + this.style = style } func (this *dbPool) unInit() {