Commit 84cec7e3 authored by Spleshka's avatar Spleshka

Issue #2232283 by Spleshka, Island Usurper, mikhailian: Frontpage is not...

Issue #2232283 by Spleshka, Island Usurper, mikhailian: Frontpage is not cleaned in Varnish by Drush because it is reported as <front> and not as / by expire.
parent f5dc56b1
......@@ -108,13 +108,19 @@ function drush_expire_absolute_url() {
function drush_expire_internal_path() {
// Get drush params.
$internal_paths = drush_get_arguments();
unset($internal_paths[0]);
$paths = drush_get_arguments();
unset($paths[0]);
foreach ($internal_paths as &$path) {
$path = $path === 'FRONT' ? '<front>' : $path;
$internal_paths = array();
foreach ($paths as &$path) {
if ($path === 'FRONT') {
$internal_paths += ExpireAPI::getFrontPageUrls();
}
else {
$internal_paths[] = $path;
}
}
// Expire internal paths.
ExpireAPI::executeExpiration($internal_paths);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment