Fixed MacOS Safari loading issue

This commit is contained in:
Eduard Urbach 2018-11-16 21:45:13 +09:00
parent dd6693a9d2
commit 2d8407eb1e
2 changed files with 6 additions and 1 deletions

View File

@ -412,7 +412,7 @@ export default class AnimeNotifier {
try { try {
json = JSON.parse(data) json = JSON.parse(data)
} catch { } catch(err) {
return return
} }

View File

@ -74,6 +74,11 @@ export default class ServerEvents {
} }
let button = document.getElementById("load-new-activities") let button = document.getElementById("load-new-activities")
if(!button) {
return
}
let buttonText = document.getElementById("load-new-activities-text") let buttonText = document.getElementById("load-new-activities-text")
let newCount = parseInt(button.dataset.count) + 1 let newCount = parseInt(button.dataset.count) + 1
button.dataset.count = newCount.toString() button.dataset.count = newCount.toString()