KeyHandler // Use spanLength for stableSort().

This commit is contained in:
ShikiSuen 2022-07-14 15:23:24 +08:00
parent 44f22973a1
commit 8af2350eab
1 changed files with 1 additions and 1 deletions

View File

@ -229,7 +229,7 @@ class KeyHandler {
if arrAnchors.isEmpty { return .init() }
//
arrAnchors = arrAnchors.stableSort { $0.keyLength > $1.keyLength }
arrAnchors = arrAnchors.stableSort { $0.spanLength > $1.spanLength }
//
for currentCandidate in arrAnchors.map(\.node.candidates).joined() {