refac
This commit is contained in:
1 parent
8862210139
commit
de2360ac07
1 file changed
+3
-1
@@ -297,7 +297,8 @@
|
|||||||
);
|
);
|
||||||
|
|
||||||
const uploadedFile = await uploadFile(localStorage.token, file, {
|
const uploadedFile = await uploadFile(localStorage.token, file, {
|
||||||
knowledge_id: knowledge.id
|
knowledge_id: knowledge.id,
|
||||||
|
directory_id: currentDirectoryId
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
toast.error(`${e}`);
|
toast.error(`${e}`);
|
||||||
return null;
|
return null;
|
||||||
@@ -376,6 +377,7 @@
|
|||||||
try {
|
try {
|
||||||
let metadata = {
|
let metadata = {
|
||||||
knowledge_id: knowledge.id,
|
knowledge_id: knowledge.id,
|
||||||
|
directory_id: currentDirectoryId,
|
||||||
// If the file is an audio file, provide the language for STT.
|
// If the file is an audio file, provide the language for STT.
|
||||||
...((file.type.startsWith('audio/') || file.type.startsWith('video/')) &&
|
...((file.type.startsWith('audio/') || file.type.startsWith('video/')) &&
|
||||||
$settings?.audio?.stt?.language
|
$settings?.audio?.stt?.language
|
||||||
|
|||||||
Reference in new issue
Block a user