[READ-ONLY] Mirror of https://github.com/probablykasper/ferrum. Music library app for Mac, Linux and Windows ferrum.kasper.space
electron linux macos music music-library music-player napi windows
0

Configure Feed

Select the types of activity you want to include in your feed.

Fix crash due to next/prev TrackInfo out of bounds

Kasper (Sep 17, 2025, 7:46 AM +0200) b4faf6ca a8b79ee7

+2 -2
+2 -2
src/components/TrackInfo.svelte
··· 189 189 function keydown(e: KeyboardEvent) { 190 190 if (check_shortcut(e, '[', { cmd_or_ctrl: true })) { 191 191 save(false) 192 - if (instance) { 192 + if (instance && instance.index - 1 >= 0) { 193 193 open_track_info(instance.ids, instance.index - 1) 194 194 } 195 195 e.preventDefault() 196 196 } else if (check_shortcut(e, ']', { cmd_or_ctrl: true })) { 197 197 save(false) 198 - if (instance) { 198 + if (instance && instance.index + 1 <= instance.ids.length - 1) { 199 199 open_track_info(instance.ids, instance.index + 1) 200 200 } 201 201