fix: detect is same packege use uniqid

pull/12372/head
Joel 1 year ago
parent 47579c86e6
commit 35ef874867

@ -43,9 +43,9 @@ const Installed: FC<Props> = ({
const hasInstalled = !!installedVersion
useEffect(() => {
if (hasInstalled && toInstallVersion === installedVersion)
if (hasInstalled && uniqueIdentifier === installedInfoPayload.uniqueIdentifier)
onInstalled()
}, [hasInstalled, toInstallVersion, installedVersion])
}, [hasInstalled])
const [isInstalling, setIsInstalling] = React.useState(false)
const { mutateAsync: installPackageFromLocal } = useInstallPackageFromLocal()

@ -52,9 +52,9 @@ const Installed: FC<Props> = ({
} = checkTaskStatus()
useEffect(() => {
if (hasInstalled && toInstallVersion === installedVersion)
if (hasInstalled && uniqueIdentifier === installedInfoPayload.uniqueIdentifier)
onInstalled()
}, [hasInstalled, toInstallVersion, installedVersion])
}, [hasInstalled])
const handleCancel = () => {
stop()

Loading…
Cancel
Save