🥅 Try/catch audio.play
This commit is contained in:
@@ -183,7 +183,11 @@ function russianRoulette({ userDisplayName, message }) {
|
|||||||
}, 1250);
|
}, 1250);
|
||||||
}
|
}
|
||||||
|
|
||||||
audio.play();
|
try {
|
||||||
|
audio.play();
|
||||||
|
} catch(e) {
|
||||||
|
// user didn't interact with the document first
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user