diff --git a/services/web/app/src/Features/UserMembership/UserMembershipMiddleware.js b/services/web/app/src/Features/UserMembership/UserMembershipMiddleware.js index bd1bef7d54..d693ace492 100644 --- a/services/web/app/src/Features/UserMembership/UserMembershipMiddleware.js +++ b/services/web/app/src/Features/UserMembership/UserMembershipMiddleware.js @@ -175,6 +175,9 @@ let UserMembershipMiddleware = { new HttpErrors.NotFoundError(`incorrect entity name: ${entityName}`) ) } + if (entityName === 'Template') { + req.params.templateId = req.params.id + } // run the list of middleware functions in series. This is essencially // a poor man's middleware runner async.eachSeries(middleware, (fn, callback) => fn(req, res, callback), next)