···11# Changelog
2233+## Next
44+- Fix error when rearranging many tracks in the queue
55+36## 0.16.4 - 2022 Jan 7
47- Fix media key shortcuts
58
+2-2
src/lib/queue.ts
···151151export function moveIndexes(indexes: number[], newIndex: number, top = false) {
152152 const ids: QueueItem[] = []
153153 queue.update((q) => {
154154- // we need to remove the last indexes first to not mess up the indexes
155155- for (const index of indexes.sort().reverse()) {
154154+ // Sort descending. We need to remove the last indexes first to not mess up the indexes
155155+ for (const index of indexes.sort((a, b) => b - a)) {
156156 ids.push(removeIndex(q, index))
157157 if (index < newIndex) {
158158 newIndex--