修复没有日志数据库时无法进行分区查询的Bug

This commit is contained in:
GoEdgeLab
2022-04-17 16:50:38 +08:00
parent 1f7e24e842
commit a35ee9279f

View File

@@ -64,6 +64,14 @@ func AllAccessLogDBs() []*dbs.DB {
for _, db := range accessLogDBMapping { for _, db := range accessLogDBMapping {
result = append(result, db) result = append(result, db)
} }
if len(result) == 0 {
db, _ := dbs.Default()
if db != nil {
result = append(result, db)
}
}
return result return result
} }