Fix xp des compétences tronc #182

La méthode splice retourne les éléments supprimées, et non pas
le tableau après suppression
This commit is contained in:
Vincent Vandemeulebrouck
2021-04-09 01:03:51 +02:00
parent f25ae66de1
commit 0ae77f6889
2 changed files with 7 additions and 7 deletions

View File

@ -22,11 +22,11 @@ export class Misc {
return (a, b) => a + b;
}
static ascending(orderFunction) {
static ascending(orderFunction = x=>x) {
return (a, b) => Misc.sortingBy(orderFunction(a), orderFunction(b));
}
static descending(orderFunction) {
static descending(orderFunction = x=>x) {
return (a, b) => Misc.sortingBy(orderFunction(b), orderFunction(a));
}