Commit 3c342aca authored by Tobias Buckdahn's avatar Tobias Buckdahn

Bugfix for numeric URL taxonomy filters

parent 529544ea
......@@ -79,6 +79,15 @@ class BrickCampPlugin extends Plugin
if ($page->template() == 'tech') {
Techs::onPageProcessed($page);
}
// convert taxonomy terms to String - see https://github.com/getgrav/grav/issues/2446
$taxonomy = $page->taxonomy();
foreach ($taxonomy as $tax => $terms) {
foreach ($terms as $key => $term) {
$taxonomy[$tax][$key] = strval($term);
}
}
$page->taxonomy($taxonomy);
}
/**
......
......@@ -106,9 +106,6 @@ abstract class Techs {
}
//unset($add[$term]);
}
// filters don't work on integer terms -> convert to String
$pagetax[$taxonomy][$key] = strval($term);
}
$pagetax[$taxonomy] = array_merge($pagetax[$taxonomy], array_keys($add));
}
......
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