Reconcile IPv6 addresses on group membership changes (#5837)

This commit is contained in:
Viktor Liu
2026-04-10 09:14:42 +08:00
committed by GitHub
parent 6e05a2ebe9
commit a1cb952764
5 changed files with 259 additions and 53 deletions

View File

@@ -4,6 +4,7 @@ import (
"context"
"errors"
"fmt"
"slices"
"strings"
"time"
"unicode"
@@ -824,6 +825,11 @@ func (am *DefaultAccountManager) processUserUpdate(ctx context.Context, transact
}
}
}
allGroupChanges := slices.Concat(removedGroups, addedGroups)
if err := am.reconcileIPv6ForGroupChanges(ctx, transaction, accountID, allGroupChanges); err != nil {
return false, nil, nil, nil, fmt.Errorf("reconcile IPv6 for group changes: %w", err)
}
}
updateAccountPeers := len(userPeers) > 0