Browse Source

sorting

master
gsd 1 year ago
parent
commit
5aa25b69ca
  1. 2
      src/api/GlobalApi.js

2
src/api/GlobalApi.js

@ -105,7 +105,7 @@ export default class GlobalApi {
else if (response[srv]['player_count'] > 0) srvs.w.push(response[srv]);
else srvs.e.push(response[srv]);
}
srvs['w'].sort((s1,s2) => s2.player_now - s1.player_now);
srvs['w'] = srvs['w'].sort((s1,s2) => s2.player_count - s1.player_count);
this.stats['servers'] = srvs;
})
.catch(err => {

Loading…
Cancel
Save