From 234339b0bdbbe6960fc2e7e0157acdbc4ae8621e Mon Sep 17 00:00:00 2001 From: Ross Date: Mon, 8 Mar 2021 11:48:16 +0000 Subject: [PATCH] . --- longs/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/longs/models.py b/longs/models.py index ec5b654b..b901c21d 100644 --- a/longs/models.py +++ b/longs/models.py @@ -171,7 +171,7 @@ class Long(models.Model): #exam_order.append(q.id) path= "{0}longs/questions/{1}".format(settings.MEDIA_ROOT, question_id) - with open(path, "w") as f: + with open(path, "w+") as f: # Loop through longimage associations f.write("[") images = []