0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00

Dynamic Routing Beta: StaticPageRouter pre-checks for redirects

refs #9601

- you can define a redirect in your routes.yaml

e.g. from `page.home` to /about/

- we have to check for a possible redirect before rendering the target static page
This commit is contained in:
kirrg001 2018-06-24 00:32:07 +02:00 committed by Katharina Irrgang
parent 4ed10aa76a
commit 0229ac9e82

View file

@ -25,6 +25,8 @@ class StaticPagesRouter extends ParentRouter {
_registerRoutes() {
this.router().use(this._prepareContext.bind(this));
this.router().param('slug', this._respectDominantRouter.bind(this));
// REGISTER: permalink for static pages
this.mountRoute(this.permalinks.getValue(), controllers.entry);