diff --git a/webapp/src/viewModel/boardTree.ts b/webapp/src/viewModel/boardTree.ts index f0902eb1b..141820115 100644 --- a/webapp/src/viewModel/boardTree.ts +++ b/webapp/src/viewModel/boardTree.ts @@ -296,6 +296,12 @@ class MutableBoardTree implements BoardTree { } let result = aValue.localeCompare(bValue) + + if (result === 0) { + // In case of "ties", use the default order + result = this.defaultOrder(a, b) + } + if (sortOption.reversed) { result = -result } @@ -375,6 +381,11 @@ class MutableBoardTree implements BoardTree { result = aValue.localeCompare(bValue) } + if (result === 0) { + // In case of "ties", use the default order + result = this.defaultOrder(a, b) + } + if (sortOption.reversed) { result = -result }