Skip to content

Commit

Permalink
chore: toast message on model import fail with reason (#3276)
Browse files Browse the repository at this point in the history
  • Loading branch information
louis-jan authored Aug 6, 2024
1 parent d074a5a commit 3bebdfe
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions web/screens/Settings/ImportingModelModal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import { useAtomValue, useSetAtom } from 'jotai'

import { AlertCircle } from 'lucide-react'

import { toaster } from '@/containers/Toast'

import useCortex from '@/hooks/useCortex'
import {
getImportModelStageAtom,
Expand Down Expand Up @@ -41,6 +43,11 @@ const ImportingModelModal = () => {
}

setImportModelError(model.path, errorMessage)
toaster({
title: 'Import failed',
description: errorMessage,
type: 'error',
})
}
}
}
Expand Down

0 comments on commit 3bebdfe

Please sign in to comment.