Skip to content

Commit 3a126a6

Browse files
committed
Ensure that graph components remain sorted until explicit randomization
1 parent 9edcd40 commit 3a126a6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/main/org/nlogo/extensions/nw/GraphContext.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import org.nlogo.api.ExtensionException
77
import org.nlogo.extensions.nw.NetworkExtensionUtil.AgentSetToRichAgentSet
88
import org.nlogo.extensions.nw.algorithms.{BreadthFirstSearch, PathFinder}
99

10-
import scala.collection.immutable.SortedSet
10+
import scala.collection.immutable.{ SortedSet, SortedMap }
1111
import scala.collection.mutable
1212
import scala.collection.mutable.ArrayBuffer
1313

@@ -141,7 +141,7 @@ with algorithms.CentralityMeasurer {
141141
.foreach(found => foundBy(found) = t)
142142
t
143143
})
144-
}.values
144+
}.to(SortedMap).values
145145
}
146146

147147
def monitoredTreeAgentSets =

0 commit comments

Comments
 (0)