diff --git a/src/stores/chats.js b/src/stores/chats.js index 86ea310ce..1cf4f4a3d 100644 --- a/src/stores/chats.js +++ b/src/stores/chats.js @@ -40,8 +40,8 @@ export const useChatsStore = defineStore('chats', { useStreamingStore().addSubscriber(socket) }, startFetching() { - this.fetcher = () => promiseInterval(() => this.fetchChats(), 5000) - this.fetcher() + this.fetcher = promiseInterval(() => this.fetchChats(), 5000) + this.fetchChats() }, stopFetching() { this.fetcher?.stop()