here's my code:
world.beforeEvents.chatSend.subscribe((eventData) => {
const player = eventData.sender;
switch (eventData.message) {
case '!gmc':
eventData.cancel = true;
player.runCommandAsync('gamemode c');
player.runCommandAsync('title @s title §a§lCreative');
player.runCommandAsync('playsound random.toast @s');
break;
case '!gms':
eventData.cancel = true;
player.runCommandAsync('gamemode s');
player.runCommandAsync('title @s title §4§lSurvival');
player.runCommandAsync('playsound random.toast @s');
break;
case '!gmsp':
eventData.cancel = true;
player.runCommandAsync('gamemode spectator');
player.runCommandAsync('title @s title §7§lSpectator');
player.runCommandAsync('playsound random.toast @s');
break;
default: break;
}
});``` . When I load my world(with all experiments and education edition turned on), there's message in chat, that says smth like "at least one addon isn't loaded". I don't know anything about code(copied this one from the wiki). Please can anyone fix the errors?