Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
fccf65ba
Commit
fccf65ba
authored
Apr 19, 2012
by
Crell
Browse files
Move frontpage handling to the PathSubscriber.
parent
47e02334
Changes
2
Hide whitespace changes
Inline
Side-by-side
core/lib/Drupal/Core/EventSubscriber/PathSubscriber.php
View file @
fccf65ba
...
...
@@ -39,6 +39,11 @@ public function onKernelRequestPathResolve(GetResponseEvent $event) {
}
$system_path
=
drupal_get_normal_path
(
$path
);
// Do our fancy frontpage logic.
if
(
empty
(
$system_path
))
{
$system_path
=
variable_get
(
'site_frontpage'
,
'user'
);
}
$request
->
attributes
->
set
(
'system_path'
,
$system_path
);
// @todo Remove this line once code has been refactored to use the request
...
...
core/lib/Drupal/Core/UrlMatcher.php
View file @
fccf65ba
...
...
@@ -94,11 +94,6 @@ public function match($pathinfo) {
$dpathinfo
=
ltrim
(
$pathinfo
,
'/'
);
}
// Do our fancy frontpage logic.
if
(
empty
(
$dpathinfo
))
{
$dpathinfo
=
variable_get
(
'site_frontpage'
,
'user'
);
}
if
(
$router_item
=
$this
->
matchDrupalItem
(
$dpathinfo
))
{
$ret
=
$this
->
convertDrupalItem
(
$router_item
);
// Stash the router item in the attributes while we're transitioning.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment