mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-28 05:15:04 +08:00
fix: 同步数据库时, 忽略recycle_bin和__recycle_bin__ (#2664)
* fix: 同步数据库时, 忽略recycle_bin改为__recycle_bin__ * fix: 同步数据库时, 忽略recycle_bin和__recycle_bin__ --------- Co-authored-by: tt <www@tt.local> Co-authored-by: shao <shao@mac.local>
This commit is contained in:
parent
3c3fd5fd78
commit
f30f561723
@ -269,7 +269,7 @@ func (r *Local) SyncDB(version string) ([]SyncDBInfo, error) {
|
||||
if len(parts) != 2 {
|
||||
continue
|
||||
}
|
||||
if parts[0] == "SCHEMA_NAME" || parts[0] == "information_schema" || parts[0] == "mysql" || parts[0] == "performance_schema" || parts[0] == "sys" || parts[0] == "__recycle_bin__" {
|
||||
if parts[0] == "SCHEMA_NAME" || parts[0] == "information_schema" || parts[0] == "mysql" || parts[0] == "performance_schema" || parts[0] == "sys" || parts[0] == "__recycle_bin__" || parts[0] == "recycle_bin" {
|
||||
continue
|
||||
}
|
||||
dataItem := SyncDBInfo{
|
||||
|
@ -279,7 +279,7 @@ func (r *Remote) SyncDB(version string) ([]SyncDBInfo, error) {
|
||||
if err = rows.Scan(&dbName, &charsetName); err != nil {
|
||||
return datas, err
|
||||
}
|
||||
if dbName == "information_schema" || dbName == "mysql" || dbName == "performance_schema" || dbName == "sys" || dbName == "__recycle_bin__" {
|
||||
if dbName == "information_schema" || dbName == "mysql" || dbName == "performance_schema" || dbName == "sys" || dbName == "__recycle_bin__" || parts[0] == "recycle_bin" {
|
||||
continue
|
||||
}
|
||||
dataItem := SyncDBInfo{
|
||||
|
Loading…
Reference in New Issue
Block a user