projects
/
vchess.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
More reliable Discord connection + show sender name when sending challenge
[vchess.git]
/
client
/
src
/
views
/
Hall.vue
diff --git
a/client/src/views/Hall.vue
b/client/src/views/Hall.vue
index
22ffe45
..
fe18941
100644
(file)
--- a/
client/src/views/Hall.vue
+++ b/
client/src/views/Hall.vue
@@
-1134,7
+1134,9
@@
export default {
this.challenges.splice(challToDelIdx, 1);
}
this.send("newchallenge", {
this.challenges.splice(challToDelIdx, 1);
}
this.send("newchallenge", {
- data: Object.assign({ from: this.st.user.sid }, chall)
+ data: Object.assign(
+ // Temporarily add sender infos to display challenge on Discord.
+ { from: this.st.user.sid, sender: this.st.user.name }, chall)
});
// Add new challenge:
chall.from = {
});
// Add new challenge:
chall.from = {
@@
-1309,6
+1311,7
@@
export default {
// on game just after, the main Hall will be notified.
};
if (c.type == "live") {
// on game just after, the main Hall will be notified.
};
if (c.type == "live") {
+ // TODO: ask my IP + opp IP, to add to game infos? (potential bans)
notifyNewgame();
this.startNewGame(gameInfo);
// Increment game stats counter in DB
notifyNewgame();
this.startNewGame(gameInfo);
// Increment game stats counter in DB