MonitoringBadgeNavigationItemRenderer: do not fail

...on wildcard filter
This commit is contained in:
Thomas Gelf 2023-02-24 08:52:46 +01:00 committed by Johannes Meyer
parent ea1e5f9245
commit 463cc748bf
1 changed files with 4 additions and 0 deletions

View File

@ -114,6 +114,10 @@ class MonitoringBadgeNavigationItemRenderer extends BadgeNavigationItemRenderer
{
$restrictions = Filter::matchAny();
foreach (Auth::getInstance()->getRestrictions($restriction) as $filter) {
if ($filter === '*') {
$filterable->addFilter(Filter::matchAll());
return $filterable;
}
$restrictions->addFilter(Filter::fromQueryString($filter));
}
$filterable->applyFilter($restrictions);