fix(webui): libraries ordering does not work on Chrome

This commit is contained in:
Gauthier Roebroeck 2025-02-20 09:41:28 +08:00
parent 174c6fdf38
commit e528c7e3d9

View file

@ -15,7 +15,7 @@ const vuexModule: Module<any, any> = {
const settings = getters.getClientSettingsLibraries
return state.libraries
.map((it: LibraryDto) => Object.assign({}, it, settings[it.id]))
.sort((a: LibraryDto, b: LibraryDto) => a.order > b.order)
.sort((a: LibraryDto, b: LibraryDto) => a.order - b.order)
},
getLibraryById: (state, getters) => (id: number) => {
return getters.getLibraries.find((l: any) => l.id === id)