diff options
Diffstat (limited to 'src/web')
| -rw-r--r-- | src/web/src/components/System/Shares/index.js | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/web/src/components/System/Shares/index.js b/src/web/src/components/System/Shares/index.js index f4f9ac94..c4282986 100644 --- a/src/web/src/components/System/Shares/index.js +++ b/src/web/src/components/System/Shares/index.js @@ -24,17 +24,18 @@ const Index = ({ state = {} } = {}) => { const [modal, setModal] = useState(false); const { scanning, scanProgress, scanPending, directories, files } = state; - const scanned = !scanning; useEffect(() => { getAll(); }, []); useEffect(() => { - if (scanned) { - getAll(); + getAll(); + + if (!scanning) { + setTimeout(() => getAll(), 1000); } - }, [scanned]); + }, [scanning, scanPending]); const getAll = async () => { try { |
