diff --git a/api/commands.py b/api/commands.py index 2246c90ab5..604fdd9c40 100644 --- a/api/commands.py +++ b/api/commands.py @@ -321,6 +321,8 @@ def migrate_knowledge_vector_database(): ) datasets = db.paginate(select=stmt, page=page, per_page=50, max_per_page=50, error_out=False) + if not datasets.items: + break except SQLAlchemyError: raise diff --git a/web/app/components/header/account-setting/model-provider-page/index.tsx b/web/app/components/header/account-setting/model-provider-page/index.tsx index 35de29185f..239c462ffe 100644 --- a/web/app/components/header/account-setting/model-provider-page/index.tsx +++ b/web/app/components/header/account-setting/model-provider-page/index.tsx @@ -93,7 +93,7 @@ const ModelProviderPage = ({ searchText }: Props) => { {defaultModelNotConfigured && (
- {t('common.modelProvider.notConfigured')} + {t('common.modelProvider.notConfigured')}
)} { + const text = hasCredential ? t('common.operation.config') : t('common.operation.setup') const Item = ( ) if (notAllowCustomCredential && !hasCredential) {