Remove interval fetching
This commit is contained in:
parent
a424c9ebc1
commit
07881c57a1
1 changed files with 1 additions and 9 deletions
|
@ -1,5 +1,5 @@
|
|||
import { SlideFade, Image, VStack, Flex, Divider, useDisclosure, useToast } from '@chakra-ui/react';
|
||||
import React, { useEffect } from 'react';
|
||||
import React from 'react';
|
||||
import { FiExternalLink } from 'react-icons/fi';
|
||||
import { AppConfig } from '../../../core/types';
|
||||
import { useAppsStore } from '../../../state/appsStore';
|
||||
|
@ -22,14 +22,6 @@ const AppDetails: React.FC<IProps> = ({ app }) => {
|
|||
|
||||
const { install, update, uninstall, stop, start, fetchApp } = useAppsStore();
|
||||
|
||||
useEffect(() => {
|
||||
const interval = setInterval(() => {
|
||||
fetchApp(app.id);
|
||||
}, 3000);
|
||||
|
||||
return () => clearInterval(interval);
|
||||
}, [app.id, fetchApp]);
|
||||
|
||||
const handleError = (error: unknown) => {
|
||||
if (error instanceof Error) {
|
||||
toast({
|
||||
|
|
Loading…
Reference in a new issue