- 替换 sqlite 驱动为 github.com/glebarez/sqlite
- 修复数据库锁定的问题 - 修复部分代码不完善的问题 - 修复策略显示不完整的问题 - 修复编辑文件换行符的问题 - 优化guacd连接
This commit is contained in:
@ -26,13 +26,6 @@ func newApp() *App {
|
||||
func init() {
|
||||
setupCache()
|
||||
app = newApp()
|
||||
if err := app.InitDBData(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
if err := app.ReloadData(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
app.Server = setupRoutes()
|
||||
}
|
||||
|
||||
func (app App) InitDBData() (err error) {
|
||||
@ -96,7 +89,15 @@ func (app App) ReloadData() error {
|
||||
|
||||
func Run() error {
|
||||
|
||||
fmt.Printf(constant.Banner, constant.Version)
|
||||
fmt.Printf(constant.AppBanner, constant.AppVersion)
|
||||
|
||||
if err := app.InitDBData(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
if err := app.ReloadData(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
app.Server = setupRoutes()
|
||||
|
||||
if config.GlobalCfg.Debug {
|
||||
jsonBytes, err := json.MarshalIndent(config.GlobalCfg, "", " ")
|
||||
|
Reference in New Issue
Block a user