From c6f10f96b64753c640f270824f2b2a64b7723124 Mon Sep 17 00:00:00 2001 From: Louis Date: Tue, 24 Dec 2024 15:09:29 +0700 Subject: [PATCH] chore: filter out engine download --- extensions/inference-cortex-extension/src/index.ts | 1 + web/containers/Providers/EventListener.tsx | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/extensions/inference-cortex-extension/src/index.ts b/extensions/inference-cortex-extension/src/index.ts index 2140a28dd3..b631a048f9 100644 --- a/extensions/inference-cortex-extension/src/index.ts +++ b/extensions/inference-cortex-extension/src/index.ts @@ -284,6 +284,7 @@ export default class JanInferenceCortexExtension extends LocalOAIEngine { transferred: transferred, total: total, }, + downloadType: data.task.type, } ) diff --git a/web/containers/Providers/EventListener.tsx b/web/containers/Providers/EventListener.tsx index bad1afda99..f28057626f 100644 --- a/web/containers/Providers/EventListener.tsx +++ b/web/containers/Providers/EventListener.tsx @@ -96,7 +96,10 @@ const EventListener = () => { const onFileDownloadSuccess = useCallback( async (state: DownloadState) => { console.debug('onFileDownloadSuccess', state) - if (state.downloadType !== 'extension') { + if ( + state.downloadType !== 'extension' && + state.downloadType !== 'Engine' + ) { // Update model metadata accordingly const model = ModelManager.instance().models.get(state.modelId) if (model) {