From 0c59d3140e020f4151e58ec0b622dda89193d14f Mon Sep 17 00:00:00 2001 From: cutls Date: Sat, 24 Dec 2022 22:40:11 +0900 Subject: [PATCH] misskey cannot show TL --- app/js/tl/misskeyparse.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/app/js/tl/misskeyparse.js b/app/js/tl/misskeyparse.js index 9dbf0f6b..c53f7479 100644 --- a/app/js/tl/misskeyparse.js +++ b/app/js/tl/misskeyparse.js @@ -278,7 +278,7 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) { } var if_notf = 'data-notfIndv="' + acct_id + "_" + toot.id + '"' var toot = toot.note - var dis_name = escapeHTML(toot.user.name) + var dis_name = escapeHTML(toot.user.name || toot.user.username) } else { var if_notf = "" if (toot.renote) { @@ -291,7 +291,7 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) { if (!toot.text) { var toot = toot.renote } - var dis_name = escapeHTML(toot.user.name) + var dis_name = escapeHTML(toot.user.name || toot.user.username) var uniqueid = toot.id var actemojick = false } else { @@ -606,9 +606,8 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) { } //Ticker var tickerdom = "" - if (ticker) { - var tickerdata = JSON.parse(localStorage.getItem("ticker")) - + var tickerdata = JSON.parse(localStorage.getItem("ticker")) + if (ticker && tickerdata) { var thisdomain = toot.user.username.split("@") if (thisdomain.length > 1) { thisdomain = thisdomain[1] @@ -798,7 +797,7 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) { '' + '' + viewer + '' + '
' + analyze + - '