mirror of
https://github.com/wassname/Open-Assistant.git
synced 2026-08-11 11:13:12 +08:00
Remove the automatic refreshing interval when in message tree (#1353)
Co-authored-by: Jonathan Fritz <fritz@nosc.io>
This commit is contained in:
co-authored by
Jonathan Fritz
parent
c66c0249ed
commit
d35220c702
@@ -15,9 +15,7 @@ const MessageDetail = ({ id }: InferGetServerSidePropsType<typeof getServerSideP
|
||||
const { t } = useTranslation(["message", "common"]);
|
||||
const backgroundColor = useColorModeValue("white", "gray.800");
|
||||
|
||||
const { isLoading: isLoadingParent, data: parent } = useSWRImmutable<Message>(`/api/messages/${id}/parent`, get, {
|
||||
refreshInterval: 30 * 1000, // 30 seconds
|
||||
});
|
||||
const { isLoading: isLoadingParent, data: parent } = useSWRImmutable<Message>(`/api/messages/${id}/parent`, get);
|
||||
|
||||
if (isLoadingParent) {
|
||||
return <MessageLoading />;
|
||||
|
||||
Reference in New Issue
Block a user