Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 313861

Aliased paths cannot be set as front page

$
0
0

Problem/Motivation

PathMatcher::isFrontPage does not work with aliased paths, causing the front page path to not redirect to the root path if an aliased path is used. Internal paths like /node/1 work fine.

  • With /homepage (path alias) as front page, visiting / redirects to /homepage
  • With /node/1 as front page, visiting / does not redirect (this is the correct behavior)

The site configuration form makes it look like the front path is the path alias, but in reality the /node/1 path is stored in system.site config. This creates a hard dependency between site content and site configuration, something that's not desirable in modern workflows.

Steps to reproduce

  1. Create a page node with alias /homepage
  2. Configure the front page path to be /homepage
  3. Visiting the front page will result in the /homepage path, instead of the root path

Proposed resolution

Change PathMatcher::isFrontPage to check both internal and aliased paths.

Remaining tasks


Viewing all articles
Browse latest Browse all 313861

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>