mirror of
https://git.rape.pet/ulith/amputoma-fe.git
synced 2025-01-31 08:33:22 +01:00
rot.js resilience
This commit is contained in:
parent
d551e7f499
commit
6b9c7e3cbd
1 changed files with 14 additions and 7 deletions
|
@ -131,12 +131,19 @@
|
||||||
|
|
||||||
//Configure by post
|
//Configure by post
|
||||||
waitUntilSpecial(".pin", (pinnedPost) => {
|
waitUntilSpecial(".pin", (pinnedPost) => {
|
||||||
if (pinnedPost.nextElementSibling
|
let p = pinnedPost.nextElementSibling;
|
||||||
.querySelector(".StatusBody")
|
if (!p)
|
||||||
.querySelector(".text")
|
return false;
|
||||||
.innerHTML
|
|
||||||
.replace(/(<([^>]+)>)/ig, '')
|
let statusBody = p.querySelector(".StatusBody");
|
||||||
.search(/profile them/ig) == -1)
|
if (!statusBody)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
let txtElm = statusBody.querySelector(".text");
|
||||||
|
if (!txtElm)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
if (txtElm.innerHTML.replace(/(<([^>]+)>)/ig, '').search(/profile them/ig) == -1)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
const ptp = pinnedPost.nextElementSibling.querySelector(".StatusBody");
|
const ptp = pinnedPost.nextElementSibling.querySelector(".StatusBody");
|
||||||
|
@ -217,7 +224,7 @@
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case "notice":
|
case "notice":
|
||||||
//Continue playing
|
applyMainTheme(); //Statuses
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
Loading…
Reference in a new issue