git.shiar.nl
/
sc2-widget
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
34a0c00
)
omit previous season ladders with listed players
author
Mischa POSLAWSKY
<perl@shiar.org>
Wed, 21 Aug 2019 23:57:51 +0000
(
01:57
+0200)
committer
Mischa POSLAWSKY
<perl@shiar.org>
Thu, 22 Aug 2019 01:15:22 +0000
(
03:15
+0200)
widget.html
patch
|
blob
|
history
diff --git
a/widget.html
b/widget.html
index c2a351dc14951302d6881a810a87acb4f191dde8..4264127a747297a49840fd9a56abb4c739f4b1be 100644
(file)
--- a/
widget.html
+++ b/
widget.html
@@
-24,6
+24,10
@@
return res.json()
})
.then(clan => {
+ let laddercmp = {}
+ clan.ladders = clan.ladders.filter(l => !(
+ laddercmp[l.members] = l.members in laddercmp
+ ))
let tiernum = (rank) => rank <= 8 ? 1 : rank <= 25 ? 2 : rank <= 50 ? 3 : 4;
let matchtime = (d) => d.getDate() + '/' + (d.getMonth() + 1) +
' ' + d.getHours() + ":" + ('0' + d.getMinutes()).slice(-2);