From 48b60fd8139ad29cf46a1d11c80000641d6acfde Mon Sep 17 00:00:00 2001 From: top Date: Mon, 19 Feb 2024 00:31:35 +0000 Subject: [PATCH] Fix stuff (#223) Fix the reversed genocide modifier. Fix the reversed genocide modifier. Co-authored-by: Chuck Reviewed-on: https://fsdfsd.net/rDrama/rDrama/pulls/223 Co-authored-by: top Co-committed-by: top --- files/assets/js/comments+post_listing.js | 1 + files/assets/js/markdown.js | 2 +- files/classes/user.py | 1 - 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/files/assets/js/comments+post_listing.js b/files/assets/js/comments+post_listing.js index 233ff1548..6d37378e2 100644 --- a/files/assets/js/comments+post_listing.js +++ b/files/assets/js/comments+post_listing.js @@ -136,6 +136,7 @@ document.addEventListener("click", function(e) { pop_instance = bootstrap.Popover.getOrCreateInstance(active, { content: popover.innerHTML, html: true, + sanitize: false, // already done on the back end, fixes complex emotes }); pop_instance.show() is_popover_visible = true diff --git a/files/assets/js/markdown.js b/files/assets/js/markdown.js index 640949f30..283bd17ee 100644 --- a/files/assets/js/markdown.js +++ b/files/assets/js/markdown.js @@ -222,7 +222,7 @@ function markdown(t) { const loveHtml = modifiers.has(MODIFIERS.LOVE) ? `` : ''; const url = modifiers.has(MODIFIERS.USER) ? `/@${emoji}/pic` : `${SITE_FULL_IMAGES}/e/${emoji}.webp`; const modifierHtml = isTalkingFirst ? `${talkingHtml}${patHtml}${loveHtml}${typingHtml}` : `${patHtml}${talkingHtml}${loveHtml}${typingHtml}`; - input = input.replace(old, `${modifierHtml}`); + input = input.replace(old, `${modifierHtml}`); } else { input = input.replace(old, ``); } diff --git a/files/classes/user.py b/files/classes/user.py index 625004fa6..1cb5c5da0 100644 --- a/files/classes/user.py +++ b/files/classes/user.py @@ -1046,7 +1046,6 @@ class User(Base): 'id': self.id } - return {'username': self.username, 'original_username': self.original_username, 'url': self.url,