Fixed prisma command response on api workspace update-embeddings
This commit is contained in:
timothycarambat 2024-04-21 11:45:34 -07:00
parent a3b7239d05
commit 37f4db36a6

View File

@ -436,9 +436,9 @@ function apiWorkspaceEndpoints(app) {
await Document.removeDocuments(currWorkspace, deletes);
await Document.addDocuments(currWorkspace, adds);
const updatedWorkspace = await Workspace.get(
`id = ${Number(currWorkspace.id)}`
);
const updatedWorkspace = await Workspace.get({
id: Number(currWorkspace.id),
});
response.status(200).json({ workspace: updatedWorkspace });
} catch (e) {
console.log(e.message, e);