Skip to content

Commit 3ffcd43

Browse files
authored
PBM-1522 Check full db name instead of a prefix (#1106)
Make sure to not skip other databases than 'admin'.
1 parent fab2e16 commit 3ffcd43

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pbm/restore/logical.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1408,7 +1408,7 @@ func (r *Restore) swapUsers(ctx context.Context, exclude *topo.AuthInfo, nss []s
14081408
for _, ns := range nss {
14091409
// ns can be "*.*" or "admin.pbmRUsers" or "admin.pbmRRoles"
14101410
db, _ := util.ParseNS(ns)
1411-
if len(db) == 0 || strings.HasPrefix(db, defs.DB) {
1411+
if len(db) == 0 || db == defs.DB {
14121412
continue
14131413
}
14141414
dbs = append(dbs, db)

0 commit comments

Comments
 (0)