f5a8c5a45d
Signed-off-by: Michael Mayer <michael@photoprism.app>
16 lines
257 B
Go
16 lines
257 B
Go
package report
|
|
|
|
import (
|
|
"sort"
|
|
)
|
|
|
|
// Sort sorts the report rows.
|
|
func Sort(rows [][]string) {
|
|
sort.Slice(rows, func(i, j int) bool {
|
|
if rows[i][0] == rows[j][0] {
|
|
return rows[i][1] < rows[j][1]
|
|
} else {
|
|
return rows[i][0] < rows[j][0]
|
|
}
|
|
})
|
|
}
|