Fix a wrong variable name caused by copy & paste

GetRemoteCandidatesStats() should not name its variable localCandidates.
This commit is contained in:
Steffen Vogel
2022-11-01 08:53:53 +01:00
committed by Artur Shellunts
parent bafaab6880
commit 7f2d498367
+2 -2
View File
@@ -93,8 +93,8 @@ func (a *Agent) GetRemoteCandidatesStats() []CandidateStats {
var res []CandidateStats
err := a.run(a.context(), func(ctx context.Context, agent *Agent) {
result := make([]CandidateStats, 0, len(agent.remoteCandidates))
for networkType, localCandidates := range agent.remoteCandidates {
for _, c := range localCandidates {
for networkType, remoteCandidates := range agent.remoteCandidates {
for _, c := range remoteCandidates {
stat := CandidateStats{
Timestamp: time.Now(),
ID: c.ID(),