Skip to content

Commit

Permalink
Add check to confirm extending sector has a volume
Browse files Browse the repository at this point in the history
  • Loading branch information
azfv authored Apr 21, 2024
1 parent d55cbdd commit c384e98
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion atc.js
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ export async function getOnlinePositions() {
activeFrequencies.forEach(function(activeFrequency) {
// Get all the sectors that use that frequency (but only the same position type as the primary position).
var frequencySectors = sectors.filter(sector => sector.Frequency == activeFrequency
&& sector.Callsign.toUpperCase().endsWith(onlineController.callsign.toUpperCase().slice(-3)));
&& sector.volumes.length > 0 && sector.Callsign.toUpperCase().endsWith(onlineController.callsign.toUpperCase().slice(-3)));
// If nothing found, continue.
if (!frequencySectors) return;
var extendedSector;
Expand Down

0 comments on commit c384e98

Please sign in to comment.