This commit is contained in:
creeper123123321 2021-08-13 17:16:47 -03:00 committed by GitHub
parent 56baa6df6a
commit b8eb214a9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -132,10 +132,12 @@ function refreshAccountList() {
function renderActions() {
actions.innerHTML = "";
if (Notification.permission === "default") {
actions.innerHTML += '<p><a href="javascript:" id="notificate">Enable notifications</a></p>';
$("#notificate").on("click", () => Notification.requestPermission().then(renderActions)); // i'm lazy
}
try {
if (Notification.permission === "default") {
actions.innerHTML += '<p><a href="javascript:" id="notificate">Enable notifications</a></p>';
$("#notificate").on("click", () => Notification.requestPermission().then(renderActions)); // i'm lazy
}
} catch (ignored) { } // Why apple??? Why you don't support notifications???
if (listenVisible) {
if (mcIdUsername != null && mcauth_code != null) {
addAction("Listen to " + mcIdUsername, () => {