[management] Fix DNS label uniqueness check on peer rename (#5679)

This commit is contained in:
Bethuel Mmbaga
2026-03-24 20:25:29 +03:00
committed by GitHub
parent 0fc63ea0ba
commit 0af5a0441f
2 changed files with 69 additions and 1 deletions

View File

@@ -249,7 +249,7 @@ func (am *DefaultAccountManager) UpdatePeer(ctx context.Context, accountID, user
if err != nil {
newLabel = ""
} else {
_, err := transaction.GetPeerIdByLabel(ctx, store.LockingStrengthNone, accountID, update.Name)
_, err := transaction.GetPeerIdByLabel(ctx, store.LockingStrengthNone, accountID, newLabel)
if err == nil {
newLabel = ""
}