diff --git a/server/src/express-app.js b/server/src/express-app.js index 2fa9cb523..6aa1969ad 100644 --- a/server/src/express-app.js +++ b/server/src/express-app.js @@ -47,7 +47,7 @@ const { extendSession, findUserByUsername, const {registerUser, getUserByUsername, isUserSuperAdmin, isUserAnAdminUser, getGroupsByUser, deleteUser, getAllUsers, checkIfUserExistByUsername, findOneUserByUsername, findMyUser, updateUser, restoreUser, updateMyUser} = require('./users'); -const {login: surveyLogin, getResponse: getSurveyResponse, saveResponse: saveSurveyResponse, publishSurvey, unpublishSurvey, getOnlineSurveys} = require('./online-survey') +const {login: surveyLogin, saveResponse: saveSurveyResponse, publishSurvey, unpublishSurvey, getOnlineSurveys} = require('./online-survey') const { getCaseDefinitions, getCaseDefinition, diff --git a/server/src/online-survey.js b/server/src/online-survey.js index 70514e5b9..b09dba9f0 100644 --- a/server/src/online-survey.js +++ b/server/src/online-survey.js @@ -35,22 +35,6 @@ const login = async (req, res) => { } } -const getResponse = async (req, res) => { - try { - - const { groupId, formResponseId } = req.params; - - console.log('getResponse', groupId, formResponseId); - - const db = new DB(groupId); - const doc = await db.get(formResponseId); - return res.status(200).send(doc); - } catch (error) { - console.error(error); - return res.status(500).send('Could not get response'); - } -}; - const saveResponse = async (req, res) => { try { const { groupId, formId } = req.params; @@ -141,7 +125,6 @@ const getOnlineSurveys = async (req, res) => { module.exports = { login, - getResponse, saveResponse, publishSurvey, unpublishSurvey,