Skip to content

Commit

Permalink
temp commit
Browse files Browse the repository at this point in the history
  • Loading branch information
kishore03109 committed Feb 23, 2024
1 parent 6a1ac28 commit 55bd0f5
Show file tree
Hide file tree
Showing 32 changed files with 421 additions and 6 deletions.
1 change: 0 additions & 1 deletion docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ services:
- .env
volumes:
- ./:/opt/isomercms-backend
- /opt/isomercms-backend/node_modules
- ${EFS_VOL_PATH}:${EFS_VOL_PATH}
- "~/.gitconfig:/etc/gitconfig"

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"start": "node --unhandled-rejections=warn -r ts-node/register/transpile-only -r tsconfig-paths/register -r dotenv/config build/server.js dotenv_config_path=/efs/isomer/.isomer.env",
"start:ecs:prod": "node --unhandled-rejections=warn -r ts-node/register/transpile-only -r tsconfig-paths/register src/server.js",
"start:ecs:staging": "node --unhandled-rejections=warn -r ts-node/register/transpile-only -r tsconfig-paths/register src/server.js",
"start::ecs:dev": "ts-node-dev --respawn src/server.js",
"start:ecs:dev": "DEBUG=express:* && ts-node-dev --respawn src/server.js",
"dev": "source .env && docker compose -f docker-compose.dev.yml up",
"test:docker": "docker run -d -p 54321:5432 --name postgres -e POSTGRES_USER=isomer -e POSTGRES_PASSWORD=password -e POSTGRES_DB=isomercms_test postgres:latest",
"test": "source .env.test && jest --runInBand",
Expand Down
159 changes: 159 additions & 0 deletions src/routes.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
GET /v2/auth/sgid/auth-url
GET /v2/auth/sgid/verify-login
POST /v2/auth/sgid/verify/multi/login
GET /v2/auth/github-redirect
GET /v2/auth
GET /v2/auth
POST /v2/auth/login
POST /v2/auth/verify
POST /v2/auth/verify
DELETE /v2/auth/logout
GET /v2/auth/whoami
GET /v2/auth/whoami
GET /v2/auth/whoami
POST /v2/metrics/feedback
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/role
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/role
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/role
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
POST /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
POST /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
POST /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>
DELETE /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/:userId
DELETE /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/:userId
DELETE /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/:userId
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/statistics
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/statistics
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/collaborators\/?(?=\/|$)/i>/statistics
GET /v2/sites
GET /v2/sites
GET /v2/sites/:siteName/lastUpdated
GET /v2/sites/:siteName/lastUpdated
GET /v2/sites/:siteName/lastUpdated
GET /v2/sites/:siteName/stagingUrl
GET /v2/sites/:siteName/stagingUrl
GET /v2/sites/:siteName/stagingUrl
GET /v2/sites/:siteName/siteUrl
GET /v2/sites/:siteName/siteUrl
GET /v2/sites/:siteName/siteUrl
GET /v2/sites/:siteName/info
GET /v2/sites/:siteName/info
GET /v2/sites/:siteName/info
GET /v2/sites/:siteName/info
GET /v2/sites/:siteName/launchInfo
GET /v2/sites/:siteName/launchInfo
GET /v2/sites/:siteName/launchInfo
GET /v2/sites/:siteName/launchInfo
POST /v2/sites/:siteName/launchSite
POST /v2/sites/:siteName/launchSite
POST /v2/sites/:siteName/launchSite
POST /v2/sites/:siteName/launchSite
GET /v2/sites/:siteName/getStagingBuildStatus
GET /v2/sites/:siteName/getStagingBuildStatus
GET /v2/sites/:siteName/getStagingBuildStatus
GET /v2/sites/:siteName/getStagingBuildStatus
POST /v2/sites/preview
GET /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/compare
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/request
GET /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/summary
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/viewed
GET /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/viewed
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/merge
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/approve
GET /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/comments
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/comments
DELETE /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/approve
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/comments/viewedComments
POST /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId
DELETE /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId
GET /v2/sites/<complex:/^\/(?:([^\/]+?))\/review\/?(?=\/|$)/i>/:requestId/blob
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/notifications\/?(?=\/|$)/i>
GET /v2/<complex:/^\/sites\/(?:([^\/]+?))\/notifications\/?(?=\/|$)/i>/allNotifications
POST /v2/<complex:/^\/sites\/(?:([^\/]+?))\/notifications\/?(?=\/|$)/i>
POST /v2/user/email/otp
POST /v2/user/email/verifyOtp
POST /v2/user/mobile/otp
POST /v2/user/mobile/verifyOtp
GET /v2/netlify-toml
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/subcollections/:subcollectionName/pages
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/:pageName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/subcollections/:subcollectionName/pages/:pageName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/:pageName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/subcollections/:subcollectionName/pages/:pageName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/:pageName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/collections\/(?:([^\/]+?))\/?(?=\/|$)/i>/subcollections/:subcollectionName/pages/:pageName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/pages
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/pages/:pageName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/pages/:pageName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/pages/:pageName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/pages/move
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections/:subcollectionName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections/:subcollectionName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections/:subcollectionName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/reorder
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections/:subcollectionName/reorder
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/move
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/collections/:collectionName/subcollections/:subcollectionName/move
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/(?:([^\/]+?))\/pages\/?(?=\/|$)/i>
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/(?:([^\/]+?))\/pages\/?(?=\/|$)/i>/:pageName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/(?:([^\/]+?))\/pages\/?(?=\/|$)/i>/:pageName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/(?:([^\/]+?))\/pages\/?(?=\/|$)/i>/:pageName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/?(?=\/|$)/i>/:resourceCategoryName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/?(?=\/|$)/i>
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/?(?=\/|$)/i>/:resourceCategoryName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/?(?=\/|$)/i>/:resourceCategoryName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/<complex:/^\/resourceRoom\/(?:([^\/]+?))\/resources\/?(?=\/|$)/i>/:resourceCategoryName/move
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/files
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/subdirectories
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media

POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/move
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/pages
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/pages/:fileName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/pages/:fileName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/media/:directoryName/pages/:fileName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/navigation
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/navigation
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/resourceRoom
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/resourceRoom
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/resourceRoom/:resourceRoomName
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/resourceRoom/:resourceRoomName
DELETE /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/resourceRoom/:resourceRoomName
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/contactUs
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/contactUs
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/homepage
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/homepage
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings/repo-password
GET /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings/repo-password
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings/repo-password
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/settings/repo-password
POST /<complex:/^\/v2\/sites\/(?:([^\/]+?))\/?(?=\/|$)/i>/admin/resetRepo
POST /formsg/create-site
POST /formsg/create-site
POST /formsg/create-site
POST /formsg/create-site
POST /formsg/launch-site
POST /formsg/launch-site
POST /formsg/launch-site
POST /formsg/launch-site
POST /formsg/repair-ggs
POST /formsg/repair-ggs
POST /formsg/repair-ggs
POST /formsg/repair-ggs
4 changes: 4 additions & 0 deletions src/routes/formsg/formsgGGsRepair.ts
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,10 @@ ${syncedRepos.map((repo) => `<li>${repo}</li>`)}
this.getGGsRepairFormSubmission
)

router.use((_req, res, next) => {
next()
})

return router
}
}
4 changes: 4 additions & 0 deletions src/routes/formsg/formsgSiteCreation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,10 @@ export class FormsgSiteCreateRouter {
this.formsgCreateSite
)

router.use((_req, res, next) => {
next()
})

return router
}
}
4 changes: 4 additions & 0 deletions src/routes/formsg/formsgSiteLaunch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,10 @@ export class FormsgSiteLaunchRouter {
this.handleSiteLaunchFormRequest
)

router.use((_req, res, next) => {
next()
})

return router
}
}
4 changes: 4 additions & 0 deletions src/routes/v2/auth.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@ class AuthRouter {
attachReadRouteHandlerWrapper(this.whoami)
)

router.use((_req, res, next) => {
next()
})

return router
}
}
Expand Down
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/collaborators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,10 @@ export class CollaboratorsRouter {
attachReadRouteHandlerWrapper(this.getCollaboratorsStatistics)
)

router.use((_req, res, next) => {
next()
})

return router
}
}
10 changes: 10 additions & 0 deletions src/routes/v2/authenticated/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,16 @@ const getAuthenticatedSubrouter = ({
authenticatedSubrouter.use("/user", usersRouter.getRouter())
authenticatedSubrouter.use("/netlify-toml", netlifyTomlV2Router.getRouter())

// authenticatedSubrouter.use((req, res, next) => {
// if (!req.route) {
// return res.status(404).send("Unknown route requested in uathenticated")
// }
// return next()
// })

authenticatedSubrouter.use((_req, res, next) => {
next()
})
return authenticatedSubrouter
}

Expand Down
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/metrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ export class MetricsRouter {
const router = express.Router({ mergeParams: true })

router.post("/feedback", this.collateUserFeedback)

router.use((_req, res, next) => {
next()
})
return router
}
}
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/netlifyToml.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ class NetlifyTomlRouter {

router.get("/", attachReadRouteHandlerWrapper(this.readNetlifyToml))

router.use((_req, res, next) => {
next()
})

return router
}
}
Expand Down
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/notifications.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,10 @@ export class NotificationsRouter {
attachWriteRouteHandlerWrapper(this.markNotificationsAsRead)
)

router.use((_req, res, next) => {
next()
})

return router
}
}
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/review.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1408,6 +1408,10 @@ export class ReviewsRouter {
attachReadRouteHandlerWrapper(this.closeReviewRequest)
)
router.get("/:requestId/blob", attachReadRouteHandlerWrapper(this.getBlob))

router.use((_req, res, next) => {
next()
})
return router
}
}
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/sites.ts
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,10 @@ export class SitesRouter {
// and endpoint can be changed to GET.
router.post("/preview", attachReadRouteHandlerWrapper(this.getPreviewInfo))

router.use((_req, res, next) => {
next()
})

return router
}
}
4 changes: 4 additions & 0 deletions src/routes/v2/authenticated/users.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,10 @@ export class UsersRouter {
attachReadRouteHandlerWrapper(this.verifyMobileNumberOtp)
)

router.use((_req, res, next) => {
next()
})

return router
}
}
3 changes: 3 additions & 0 deletions src/routes/v2/authenticatedSites/collectionPages.js
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,9 @@ class CollectionPagesRouter {
attachRollbackRouteHandlerWrapper(this.deleteCollectionPage)
)

router.use((_req, res, next) => {
next()
})
return router
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/routes/v2/authenticatedSites/collections.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,9 @@ class CollectionsRouter {
attachRollbackRouteHandlerWrapper(this.moveCollectionDirectoryPages)
)

router.use((_req, res, next) => {
next()
})
return router
}
}
Expand Down
4 changes: 3 additions & 1 deletion src/routes/v2/authenticatedSites/contactUs.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ class ContactUsRouter {

router.get("/", attachReadRouteHandlerWrapper(this.readContactUs))
router.post("/", attachRollbackRouteHandlerWrapper(this.updateContactUs))

router.use((_req, res, next) => {
next()
})
return router
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/routes/v2/authenticatedSites/homepage.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ class HomepageRouter {
router.get("/", attachReadRouteHandlerWrapper(this.readHomepage))
router.post("/", attachRollbackRouteHandlerWrapper(this.updateHomepage))

router.use((_req, res, next) => {
next()
})
return router
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/routes/v2/authenticatedSites/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,9 @@ const getAuthenticatedSitesSubrouter = ({
authenticatedSitesSubrouter.use("/settings", settingsV2Router.getRouter())
authenticatedSitesSubrouter.use("/admin", repoManagementV2Router.getRouter())
authenticatedSitesSubrouter.use(notificationOnEditHandler.createNotification)
authenticatedSitesSubrouter.use((_req, res, next) => {
next()
})

return authenticatedSitesSubrouter
}
Expand Down
Loading

0 comments on commit 55bd0f5

Please sign in to comment.