diff options
Diffstat (limited to 'ui/app/controllers/CControllerHost.php')
-rw-r--r-- | ui/app/controllers/CControllerHost.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ui/app/controllers/CControllerHost.php b/ui/app/controllers/CControllerHost.php index ef7d495bc6a..8bcedcd39b5 100644 --- a/ui/app/controllers/CControllerHost.php +++ b/ui/app/controllers/CControllerHost.php @@ -298,10 +298,15 @@ abstract class CControllerHost extends CController { * @return array */ protected function cleanInput(array $input): array { + if (array_key_exists('filter_reset', $input) && $input['filter_reset']) { + return array_intersect_key(['filter_name' => ''], $input); + } + if (array_key_exists('tags', $input) && $input['tags']) { $input['tags'] = array_filter($input['tags'], function($tag) { return !($tag['tag'] === '' && $tag['value'] === ''); }); + $input['tags'] = array_values($input['tags']); } return $input; |