From d9335ee0f0a9282dc373cd8a7fd8e1f2749d7799 Mon Sep 17 00:00:00 2001 From: Joey Yakimowich-Payne Date: Sat, 15 Feb 2020 08:52:13 -0700 Subject: [PATCH] Tighten updateThread fields and add todos --- src/forum.nim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/forum.nim b/src/forum.nim index 6c6f55a..cb069af 100644 --- a/src/forum.nim +++ b/src/forum.nim @@ -1197,6 +1197,8 @@ routes: resp Http400, $(%exc.data), "application/json" post "/updateThread": + # TODO: Add some way of keeping track of modifications for historical + # purposes createTFD() if not c.loggedIn(): let err = PostError( @@ -1211,7 +1213,9 @@ routes: let threadId = formData["threadId"].body - let keys = ["name", "views", "modified", "category", "isLocked", "solution", "isDeleted"] + # TODO: might want to add more properties here under a tighter permissions + # model + let keys = ["name", "category", "solution"] # optional parameters var