forked from rDrama/rDrama
1
0
Fork 0

fix hat persisting on hatless users in popover

master
Aevann 2023-07-22 14:25:37 +03:00
parent 59efc521ff
commit fd10a0ad87
1 changed files with 3 additions and 0 deletions

View File

@ -109,6 +109,9 @@ document.addEventListener("click", function(e) {
if (author["hat"]) {
popover.getElementsByClassName('pop-hat')[0].src = author['hat'] + "?h=7"
}
else {
popover.getElementsByClassName('pop-hat')[0].removeAttribute('src');
}
popover.getElementsByClassName('pop-username')[0].innerHTML = author["username"]
if (popover.getElementsByClassName('pop-bio').length > 0) {
popover.getElementsByClassName('pop-bio')[0].innerHTML = author["bio_html"]