diff options
| author | HumairAK <humair88@hotmail.com> | 2016-07-27 00:49:21 +0000 |
|---|---|---|
| committer | HumairAK <humair88@hotmail.com> | 2016-07-27 00:49:21 +0000 |
| commit | 7e30cb0b87d8ead0b4746238c533630f252619ef (patch) | |
| tree | a19851ef823fa4c48aea9d267a1cb3c8adbcac84 /routes/index.js | |
| parent | 20220f9c3cf0cf8e1efbe850aba4a99f23d9a0cb (diff) | |
fixed csrf and redirect issues with follow exam
Diffstat (limited to 'routes/index.js')
| -rw-r--r-- | routes/index.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/routes/index.js b/routes/index.js index 219b7b7..d631d7b 100644 --- a/routes/index.js +++ b/routes/index.js @@ -184,7 +184,8 @@ router.get('/questions/:exam_id', function (req,res) { pageCount : exam.page_count, questionCount : exam.questions_count }; - res.render('questions', {query: qList, examInfo: examInfo}); + res.render('questions', {query: qList, examInfo: examInfo, csrfToken: req.csrfToken()}); + req.session.messages = null; }); }else{ req.session.messages = {error : "Could not find exam."}; |
