Sort buffers by network
This commit is contained in:
parent
002b91a599
commit
d2ff88d946
1 changed files with 7 additions and 0 deletions
|
@ -69,6 +69,13 @@ function debounce(f, delay) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function compareBuffers(a, b) {
|
function compareBuffers(a, b) {
|
||||||
|
if (a.network < b.network) {
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
if (a.network > b.network) {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
if (a.type == BufferType.SERVER) {
|
if (a.type == BufferType.SERVER) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue