def add_questions(email, classroom, questions):
print(classroom + " " + str(questions))
db.sessions.update_one({ #questions added to session coming up.
"email": email,
"status": "on",
"classroom": classroom
}, {
"$set": {
"questions": questions
}
})
https://i.stack.imgur.com/WxxbL.png
That is the structure (in the image).
But it isn't updating? I want to replace the old questions array (as you see in the image) to the new one from my params.