diff --git a/services/backend/src/routes.ts b/services/backend/src/routes.ts index 2c3cd61771..9bc21edf7c 100644 --- a/services/backend/src/routes.ts +++ b/services/backend/src/routes.ts @@ -91,55 +91,3 @@ const routes = (app: Express, url: string) => { } export default routes - -// module.exports = (app, url) => { -// initializeSentry(app) - -// app.use(Sentry.Handlers.requestHandler()) -// app.use(Sentry.Handlers.tracingHandler()) - -// app.use(cors({ credentials: true, origin: frontUrl })) -// app.use(express.json()) -// app.use(compression()) - -// app.use(headersMiddleware) -// app.use(currentUserMiddleware) -// app.use(accessLogger) -// app.use(`${url}/login`, login) -// app.use(url, courses) -// app.use(`${url}/students`, students) -// app.use(url, population) -// app.use(`${url}/providers`, providers) -// app.use(`${url}/semesters/codes`, semesters) -// app.use(url, tags) -// app.use(url, programmeModules) -// app.use(`${url}/v3/course_exclusions`, courseExclusions) -// app.use(`${url}/v2/studyprogrammes`, studyProgramme) -// app.use(`${url}/programmecriteria`, studyProgrammeCriteria) -// app.use(`${url}/openunisearch`, auth.roles(['openUniSearch']), customOpenUniSearch) -// app.use(`${url}/changelog`, changelog) -// app.use(`${url}/completedcoursessearch`, completedCoursesSearch) -// app.use(`${url}/languagecenterdata`, languageCenterData) -// app.use(`${url}/faculties`, faculties) -// app.use(`${url}/university`, university) -// app.use(`${url}/updater`, auth.roles(['admin']), updater) -// app.use(`${url}/teachers`, auth.roles(['teachers']), teachers) -// if (serviceProvider === 'toska') { -// app.use(`${url}/users`, usersToska) -// } else { -// app.use(`${url}/users`, usersToska) -// app.use(`${url}/users`, usersFd) -// } -// app.use(`${url}/feedback`, feedback) -// app.use(`${url}/custom-population-search`, customPopulationSearch) -// app.use(`${url}/studyguidancegroups`, auth.roles(['studyGuidanceGroups']), studyGuidanceGroups) -// app.use(`${url}/close-to-graduation`, auth.roles(['fullSisuAccess', 'studyGuidanceGroups']), closeToGraduation) -// app.use(`${url}/study-programme-pins`, studyProgrammePins) -// app.use(`${url}/curriculum-periods`, curriculumPeriods) -// app.get('*', async (_, res) => { -// const results = { error: 'unknown endpoint' } -// res.status(404).json(results) -// }) -// app.use(Sentry.Handlers.errorHandler()) -// app.use(errorHandler) -// }