Correct the switch case and add information to the warning.
This commit is contained in:
parent
db464aa808
commit
d241f341be
1 changed files with 2 additions and 2 deletions
|
|
@ -52,7 +52,7 @@ export default {
|
|||
return;
|
||||
};
|
||||
|
||||
switch (data.mode) {
|
||||
switch (data.action) {
|
||||
case "modify":
|
||||
if (this.$store.state.name === data.name) {
|
||||
this.$store.commit(`player`, {
|
||||
|
|
@ -67,7 +67,7 @@ export default {
|
|||
this.$store.commit(`playerList`, data.players);
|
||||
break;
|
||||
default:
|
||||
console.warn(`Unknown response type from "PlayerUpdate"`);
|
||||
console.warn(`Unknown response type from "PlayerUpdate": ${data.mode}`);
|
||||
};
|
||||
},
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue