fixup! show sender on message
All checks were successful
Build and test backend / Build-backend (pull_request) Successful in 2m8s
Build and test FrontEnd / Build-frontend (pull_request) Successful in 24s

This commit is contained in:
Debucquoy Anthony 2024-04-02 10:18:50 +02:00
parent ccb954e348
commit 2b9bdf8dac
Signed by: tonitch
GPG Key ID: A78D6421F083D42E

View File

@ -15,6 +15,7 @@ import { ref } from 'vue'
*/ */
export const discussionsList = ref(); export const discussionsList = ref();
export const currentDiscussion = ref([]); export const currentDiscussion = ref([]);
let timerSet = false
export async function createDiscussion(name){ export async function createDiscussion(name){
@ -50,6 +51,10 @@ async function fetchDiscussions(){
export async function fetchDiscussion(id){ export async function fetchDiscussion(id){
currentDiscussion.value = await restGet("/discussion/" + id); currentDiscussion.value = await restGet("/discussion/" + id);
if(!timerSet){
timerSet = true;
setTimeout(() => {timerSet = false;fetchDiscussion(currentDiscussion.value.id)} , 5000);
}
} }
await fetchDiscussions(); await fetchDiscussions();