Skip to content

Commit

Permalink
Merge pull request #1412 from jasonlyc/bug_fix
Browse files Browse the repository at this point in the history
fix seq reference error in conn check event handler of routing plugin
  • Loading branch information
MelvinTo authored Nov 13, 2024
2 parents c3703f5 + 7b4f510 commit 83249af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/routing/routing_plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -1107,9 +1107,9 @@ class RoutingPlugin extends Plugin {
break;
}
case "primary_standby": {
const activeWanPlugins = this.getActiveWANPlugins();
const activeWanStatus = Object.values(this._wanStatus).filter(status => status.active).sort((a, b) => a.seq - b.seq);
const failback = (this.networkConfig["default"] && this.networkConfig["default"].failback) || false;
if (_.isEmpty(activeWanPlugins) || (failback && currentStatus.seq < activeWanPlugins[0].seq))
if (_.isEmpty(activeWanStatus) || (failback && currentStatus.seq < activeWanStatus[0].seq))
// apply WAN settings in failback mode if a WAN with higher rank is back to ready
changeActiveWanNeeded = true;
break;
Expand Down

0 comments on commit 83249af

Please sign in to comment.