Node.js based forum software built for the modern web
fix: only render preview on topic page
Barış Soner Uşaklıa9f81215cfe4
diff --git a/public/src/client/topic.js b/public/src/client/topic.jsindex f481b200ec..231377967e 100644--- a/public/src/client/topic.js+++ b/public/src/client/topic.js@@ -190,7 +190,8 @@ define('forum/topic', [async function renderPost(pid) {const postData = postCache[pid] || await socket.emit('posts.getPostSummaryByPid', { pid: pid });- if (postData) {+ $('#post-tooltip').remove();+ if (postData && ajaxify.data.template.topic) {postCache[pid] = postData;const tooltip = await app.parseAndTranslate('partials/topic/post-preview', { post: postData });tooltip.hide().find('.timeago').timeago();