From 37f4db36a6bbc99d5bea098ae126e06845dd0c05 Mon Sep 17 00:00:00 2001 From: timothycarambat Date: Sun, 21 Apr 2024 11:45:34 -0700 Subject: [PATCH] resolves #1156 Fixed prisma command response on api workspace update-embeddings --- server/endpoints/api/workspace/index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/endpoints/api/workspace/index.js b/server/endpoints/api/workspace/index.js index 12260287..fbfdde88 100644 --- a/server/endpoints/api/workspace/index.js +++ b/server/endpoints/api/workspace/index.js @@ -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);