fix: 修正meili_search_config类型

This commit is contained in:
2025-11-05 07:16:34 +00:00
parent 326c6a005c
commit bda850e097
2 changed files with 4 additions and 4 deletions

View File

@ -118,11 +118,11 @@ export default defineEndpoint({
if (meiliConfigs.length === 0) { if (meiliConfigs.length === 0) {
return res.status(500).json({ success: false, message: 'MeiliSearch 全局配置未设置' }); return res.status(500).json({ success: false, message: 'MeiliSearch 全局配置未设置' });
} }
const { host, apiKey } = meiliConfigs[0] || { host: '', apiKey: '' }; const { host, api_key } = meiliConfigs[0] || { host: '', api_key: '' };
const client = new MeiliSearch({ const client = new MeiliSearch({
host, host: host,
apiKey, apiKey: api_key,
}) })
const result: any[] = []; const result: any[] = [];

View File

@ -3,7 +3,7 @@
*/ */
export interface MeiliSearchConfig { export interface MeiliSearchConfig {
host: string; host: string;
apiKey: string; api_key: string;
} }
/** /**