This commit is contained in:
parent
229e6903fd
commit
babd098d18
2 changed files with 3 additions and 7 deletions
|
@ -141,7 +141,6 @@ class Room extends ElemJS {
|
||||||
} else {
|
} else {
|
||||||
string += (4000000000000 - this.timeline.latest) // good until 2065 :)
|
string += (4000000000000 - this.timeline.latest) // good until 2065 :)
|
||||||
}
|
}
|
||||||
console.log(string)
|
|
||||||
return string
|
return string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -73,14 +73,11 @@ class SubscribeMapList extends Subscribable {
|
||||||
|
|
||||||
sortByString() {
|
sortByString() {
|
||||||
this.list.sort((a, b) => {
|
this.list.sort((a, b) => {
|
||||||
let r
|
|
||||||
const orderA = this.map.get(a).value().order
|
const orderA = this.map.get(a).value().order
|
||||||
const orderB = this.map.get(b).value().order
|
const orderB = this.map.get(b).value().order
|
||||||
if (orderA < orderB) r = -1
|
if (orderA < orderB) return -1
|
||||||
else if (orderA > orderB) r = 1
|
else if (orderA > orderB) return 1
|
||||||
else r = 0
|
else return 0
|
||||||
console.log("comparing", orderA, orderB, r)
|
|
||||||
return r
|
|
||||||
})
|
})
|
||||||
this.broadcast("changeItem")
|
this.broadcast("changeItem")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue