mirror of
https://github.com/spacebarchat/client.git
synced 2024-11-24 19:32:34 +01:00
use -1 as fallback in channel position sorting
This commit is contained in:
parent
ae44cce733
commit
4a79ae5b6b
@ -132,7 +132,7 @@ export function hexToRGB(hex: string) {
|
||||
}
|
||||
|
||||
export function compareChannels(a: Channel, b: Channel): number {
|
||||
return (a.position ?? 0) - (b.position ?? 0);
|
||||
return (a.position ?? -1) - (b.position ?? -1);
|
||||
}
|
||||
|
||||
export function doFit(width: number, height: number, maxWidth: number, maxHeight: number, minWidth = 0, minHeight = 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user