From 57ed6165eabef0ad0b958ec4b3256446021c9f88 Mon Sep 17 00:00:00 2001 From: Xamora Date: Tue, 19 Dec 2023 12:42:46 +0100 Subject: [PATCH] bug issue; rewrite all messages --- frontend/static/js/views/Search.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/frontend/static/js/views/Search.js b/frontend/static/js/views/Search.js index 7a706c7..924ad56 100644 --- a/frontend/static/js/views/Search.js +++ b/frontend/static/js/views/Search.js @@ -135,7 +135,10 @@ export default class extends AbstractView { // les messages, réecriture seulement du dernier let i = 0; client.channel.messages.forEach((message) => { - if (messages[i] == null || message != messages.children[i].innerText) { + if (messages.children[i] == null || message.content != messages.children[i].innerText) { + console.log(message.content); + if (messages.children[i] != null) + console.log(messages.children[i].innerText); let text = document.createElement("p"); text.appendChild(document.createTextNode(message.content)); if (message.author_id == client.me.user_id)