fixed the python error

This commit is contained in:
Niharika Goulikar
2024-11-26 13:05:50 +00:00
parent faf031ce80
commit 9d4aee5de2

View File

@@ -198,10 +198,10 @@ class SubmitFeedback(Resource):
try:
conversations_collection.update_one(
{"_id": ObjectId(data["conversation_id"]), f"queries.{data["question_index"]}": {"$exists": True}},
{"_id": ObjectId(data["conversation_id"]), f"queries.{data['question_index']}": {"$exists": True}},
{
"$set": {
f"queries.{data["question_index"]}.feedback": data["feedback"]
f"queries.{data['question_index']}.feedback": data["feedback"]
}
}
)