{"action":"created","comment":{"url":"https://api.github.com/repos/bolt/bolt/pulls/comments/55934867","id":55934867,"diff_hunk":"@@ -116,10 +116,15 @@ public function overview(Request $request, $contenttypeslug)\n             }\n         }\n \n+        $filter = null;\n+        if ($request->query->get('filter') !== \"\") {\n+            $filter = $request->query->get('filter');\n+        }\n+\n         $options = (new ListingOptions())\n             ->setOrder($request->query->get('order'))\n             ->setPage($request->query->get('page_' . $contenttypeslug))\n-            ->setFilter($request->query->get('filter'))\n+            ->setFilter($filter)","path":"src/Controller/Backend/Records.php","position":13,"original_position":13,"commit_id":"0da3f9391168b77d54884fe9bb274554a737e5c9","original_commit_id":"0da3f9391168b77d54884fe9bb274554a737e5c9","user":{"login":"GawainLynch","id":1427081,"avatar_url":"https://avatars.githubusercontent.com/u/1427081?v=3","gravatar_id":"","url":"https://api.github.com/users/GawainLynch","html_url":"https://github.com/GawainLynch","followers_url":"https://api.github.com/users/GawainLynch/followers","following_url":"https://api.github.com/users/GawainLynch/following{/other_user}","gists_url":"https://api.github.com/users/GawainLynch/gists{/gist_id}","starred_url":"https://api.github.com/users/GawainLynch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GawainLynch/subscriptions","organizations_url":"https://api.github.com/users/GawainLynch/orgs","repos_url":"https://api.github.com/users/GawainLynch/repos","events_url":"https://api.github.com/users/GawainLynch/events{/privacy}","received_events_url":"https://api.github.com/users/GawainLynch/received_events","type":"User","site_admin":false},"body":"This should be handled in the `ListingOptions` setter.\r\n\r\n```\r\n    /**\r\n     * Set the filter.\r\n     *\r\n     * @param string|null $filter\r\n     *\r\n     * @return ListingOptions\r\n     */\r\n    public function setFilter($filter)\r\n    {\r\n        $this->filter = $filter ?: null;\r\n\r\n        return $this;\r\n    }\r\n```","created_at":"2016-03-13T10:11:30Z","updated_at":"2016-03-13T10:11:30Z","html_url":"https://github.com/bolt/bolt/pull/5013#discussion_r55934867","pull_request_url":"https://api.github.com/repos/bolt/bolt/pulls/5013","_links":{"self":{"href":"https://api.github.com/repos/bolt/bolt/pulls/comments/55934867"},"html":{"href":"https://github.com/bolt/bolt/pull/5013#discussion_r55934867"},"pull_request":{"href":"https://api.github.com/repos/bolt/bolt/pulls/5013"}}},"pull_request":{"url":"https://api.github.com/repos/bolt/bolt/pulls/5013","id":62667034,"html_url":"https://github.com/bolt/bolt/pull/5013","diff_url":"https://github.com/bolt/bolt/pull/5013.diff","patch_url":"https://github.com/bolt/bolt/pull/5013.patch","issue_url":"https://api.github.com/repos/bolt/bolt/issues/5013","number":5013,"state":"open","locked":false,"title":"Don't filter on empty strings","user":{"login":"SahAssar","id":5096632,"avatar_url":"https://avatars.githubusercontent.com/u/5096632?v=3","gravatar_id":"","url":"https://api.github.com/users/SahAssar","html_url":"https://github.com/SahAssar","followers_url":"https://api.github.com/users/SahAssar/followers","following_url":"https://api.github.com/users/SahAssar/following{/other_user}","gists_url":"https://api.github.com/users/SahAssar/gists{/gist_id}","starred_url":"https://api.github.com/users/SahAssar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SahAssar/subscriptions","organizations_url":"https://api.github.com/users/SahAssar/orgs","repos_url":"https://api.github.com/users/SahAssar/repos","events_url":"https://api.github.com/users/SahAssar/events{/privacy}","received_events_url":"https://api.github.com/users/SahAssar/received_events","type":"User","site_admin":false},"body":"By default when filtering on a taxonomy you get a query string like this: \"?taxonomy-chapters=main&filter=\" which then makes bolt \"filter\" the content with a empty string, which means that you get this:\r\n![skarmklipp 2016-03-13 10 32 38](https://cloud.githubusercontent.com/assets/5096632/13728045/abe3f6a8-e90a-11e5-8678-0d56871ea109.png)\r\n","created_at":"2016-03-13T10:00:16Z","updated_at":"2016-03-13T10:11:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"24d9c1b6930acb45cb2cfeaa83d43accf5a10cbc","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/bolt/bolt/pulls/5013/commits","review_comments_url":"https://api.github.com/repos/bolt/bolt/pulls/5013/comments","review_comment_url":"https://api.github.com/repos/bolt/bolt/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bolt/bolt/issues/5013/comments","statuses_url":"https://api.github.com/repos/bolt/bolt/statuses/0da3f9391168b77d54884fe9bb274554a737e5c9","head":{"label":"SahAssar:don't-filter-on-empty","ref":"don't-filter-on-empty","sha":"0da3f9391168b77d54884fe9bb274554a737e5c9","user":{"login":"SahAssar","id":5096632,"avatar_url":"https://avatars.githubusercontent.com/u/5096632?v=3","gravatar_id":"","url":"https://api.github.com/users/SahAssar","html_url":"https://github.com/SahAssar","followers_url":"https://api.github.com/users/SahAssar/followers","following_url":"https://api.github.com/users/SahAssar/following{/other_user}","gists_url":"https://api.github.com/users/SahAssar/gists{/gist_id}","starred_url":"https://api.github.com/users/SahAssar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SahAssar/subscriptions","organizations_url":"https://api.github.com/users/SahAssar/orgs","repos_url":"https://api.github.com/users/SahAssar/repos","events_url":"https://api.github.com/users/SahAssar/events{/privacy}","received_events_url":"https://api.github.com/users/SahAssar/received_events","type":"User","site_admin":false},"repo":{"id":50508640,"name":"bolt","full_name":"SahAssar/bolt","owner":{"login":"SahAssar","id":5096632,"avatar_url":"https://avatars.githubusercontent.com/u/5096632?v=3","gravatar_id":"","url":"https://api.github.com/users/SahAssar","html_url":"https://github.com/SahAssar","followers_url":"https://api.github.com/users/SahAssar/followers","following_url":"https://api.github.com/users/SahAssar/following{/other_user}","gists_url":"https://api.github.com/users/SahAssar/gists{/gist_id}","starred_url":"https://api.github.com/users/SahAssar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SahAssar/subscriptions","organizations_url":"https://api.github.com/users/SahAssar/orgs","repos_url":"https://api.github.com/users/SahAssar/repos","events_url":"https://api.github.com/users/SahAssar/events{/privacy}","received_events_url":"https://api.github.com/users/SahAssar/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/SahAssar/bolt","description":"Bolt is a simple CMS written in PHP. It is based on Silex and Symfony components, uses Twig and either SQLite, MySQL or PostgreSQL.","fork":true,"url":"https://api.github.com/repos/SahAssar/bolt","forks_url":"https://api.github.com/repos/SahAssar/bolt/forks","keys_url":"https://api.github.com/repos/SahAssar/bolt/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SahAssar/bolt/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SahAssar/bolt/teams","hooks_url":"https://api.github.com/repos/SahAssar/bolt/hooks","issue_events_url":"https://api.github.com/repos/SahAssar/bolt/issues/events{/number}","events_url":"https://api.github.com/repos/SahAssar/bolt/events","assignees_url":"https://api.github.com/repos/SahAssar/bolt/assignees{/user}","branches_url":"https://api.github.com/repos/SahAssar/bolt/branches{/branch}","tags_url":"https://api.github.com/repos/SahAssar/bolt/tags","blobs_url":"https://api.github.com/repos/SahAssar/bolt/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SahAssar/bolt/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SahAssar/bolt/git/refs{/sha}","trees_url":"https://api.github.com/repos/SahAssar/bolt/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SahAssar/bolt/statuses/{sha}","languages_url":"https://api.github.com/repos/SahAssar/bolt/languages","stargazers_url":"https://api.github.com/repos/SahAssar/bolt/stargazers","contributors_url":"https://api.github.com/repos/SahAssar/bolt/contributors","subscribers_url":"https://api.github.com/repos/SahAssar/bolt/subscribers","subscription_url":"https://api.github.com/repos/SahAssar/bolt/subscription","commits_url":"https://api.github.com/repos/SahAssar/bolt/commits{/sha}","git_commits_url":"https://api.github.com/repos/SahAssar/bolt/git/commits{/sha}","comments_url":"https://api.github.com/repos/SahAssar/bolt/comments{/number}","issue_comment_url":"https://api.github.com/repos/SahAssar/bolt/issues/comments{/number}","contents_url":"https://api.github.com/repos/SahAssar/bolt/contents/{+path}","compare_url":"https://api.github.com/repos/SahAssar/bolt/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SahAssar/bolt/merges","archive_url":"https://api.github.com/repos/SahAssar/bolt/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SahAssar/bolt/downloads","issues_url":"https://api.github.com/repos/SahAssar/bolt/issues{/number}","pulls_url":"https://api.github.com/repos/SahAssar/bolt/pulls{/number}","milestones_url":"https://api.github.com/repos/SahAssar/bolt/milestones{/number}","notifications_url":"https://api.github.com/repos/SahAssar/bolt/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SahAssar/bolt/labels{/name}","releases_url":"https://api.github.com/repos/SahAssar/bolt/releases{/id}","deployments_url":"https://api.github.com/repos/SahAssar/bolt/deployments","created_at":"2016-01-27T13:21:27Z","updated_at":"2016-01-27T13:21:30Z","pushed_at":"2016-03-13T09:55:40Z","git_url":"git://github.com/SahAssar/bolt.git","ssh_url":"git@github.com:SahAssar/bolt.git","clone_url":"https://github.com/SahAssar/bolt.git","svn_url":"https://github.com/SahAssar/bolt","homepage":"","size":56859,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"release/2.2"}},"base":{"label":"bolt:master","ref":"master","sha":"13e2482b9c8e5e1dd09ac984a76f0eb7cc7fd8e8","user":{"login":"bolt","id":3869752,"avatar_url":"https://avatars.githubusercontent.com/u/3869752?v=3","gravatar_id":"","url":"https://api.github.com/users/bolt","html_url":"https://github.com/bolt","followers_url":"https://api.github.com/users/bolt/followers","following_url":"https://api.github.com/users/bolt/following{/other_user}","gists_url":"https://api.github.com/users/bolt/gists{/gist_id}","starred_url":"https://api.github.com/users/bolt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bolt/subscriptions","organizations_url":"https://api.github.com/users/bolt/orgs","repos_url":"https://api.github.com/users/bolt/repos","events_url":"https://api.github.com/users/bolt/events{/privacy}","received_events_url":"https://api.github.com/users/bolt/received_events","type":"Organization","site_admin":false},"repo":{"id":4665416,"name":"bolt","full_name":"bolt/bolt","owner":{"login":"bolt","id":3869752,"avatar_url":"https://avatars.githubusercontent.com/u/3869752?v=3","gravatar_id":"","url":"https://api.github.com/users/bolt","html_url":"https://github.com/bolt","followers_url":"https://api.github.com/users/bolt/followers","following_url":"https://api.github.com/users/bolt/following{/other_user}","gists_url":"https://api.github.com/users/bolt/gists{/gist_id}","starred_url":"https://api.github.com/users/bolt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bolt/subscriptions","organizations_url":"https://api.github.com/users/bolt/orgs","repos_url":"https://api.github.com/users/bolt/repos","events_url":"https://api.github.com/users/bolt/events{/privacy}","received_events_url":"https://api.github.com/users/bolt/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/bolt/bolt","description":"Bolt is a simple CMS written in PHP. It is based on Silex and Symfony components, uses Twig and either SQLite, MySQL or PostgreSQL.","fork":false,"url":"https://api.github.com/repos/bolt/bolt","forks_url":"https://api.github.com/repos/bolt/bolt/forks","keys_url":"https://api.github.com/repos/bolt/bolt/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bolt/bolt/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bolt/bolt/teams","hooks_url":"https://api.github.com/repos/bolt/bolt/hooks","issue_events_url":"https://api.github.com/repos/bolt/bolt/issues/events{/number}","events_url":"https://api.github.com/repos/bolt/bolt/events","assignees_url":"https://api.github.com/repos/bolt/bolt/assignees{/user}","branches_url":"https://api.github.com/repos/bolt/bolt/branches{/branch}","tags_url":"https://api.github.com/repos/bolt/bolt/tags","blobs_url":"https://api.github.com/repos/bolt/bolt/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bolt/bolt/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bolt/bolt/git/refs{/sha}","trees_url":"https://api.github.com/repos/bolt/bolt/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bolt/bolt/statuses/{sha}","languages_url":"https://api.github.com/repos/bolt/bolt/languages","stargazers_url":"https://api.github.com/repos/bolt/bolt/stargazers","contributors_url":"https://api.github.com/repos/bolt/bolt/contributors","subscribers_url":"https://api.github.com/repos/bolt/bolt/subscribers","subscription_url":"https://api.github.com/repos/bolt/bolt/subscription","commits_url":"https://api.github.com/repos/bolt/bolt/commits{/sha}","git_commits_url":"https://api.github.com/repos/bolt/bolt/git/commits{/sha}","comments_url":"https://api.github.com/repos/bolt/bolt/comments{/number}","issue_comment_url":"https://api.github.com/repos/bolt/bolt/issues/comments{/number}","contents_url":"https://api.github.com/repos/bolt/bolt/contents/{+path}","compare_url":"https://api.github.com/repos/bolt/bolt/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bolt/bolt/merges","archive_url":"https://api.github.com/repos/bolt/bolt/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bolt/bolt/downloads","issues_url":"https://api.github.com/repos/bolt/bolt/issues{/number}","pulls_url":"https://api.github.com/repos/bolt/bolt/pulls{/number}","milestones_url":"https://api.github.com/repos/bolt/bolt/milestones{/number}","notifications_url":"https://api.github.com/repos/bolt/bolt/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bolt/bolt/labels{/name}","releases_url":"https://api.github.com/repos/bolt/bolt/releases{/id}","deployments_url":"https://api.github.com/repos/bolt/bolt/deployments","created_at":"2012-06-14T16:07:54Z","updated_at":"2016-03-13T09:29:53Z","pushed_at":"2016-03-13T10:00:16Z","git_url":"git://github.com/bolt/bolt.git","ssh_url":"git@github.com:bolt/bolt.git","clone_url":"https://github.com/bolt/bolt.git","svn_url":"https://github.com/bolt/bolt","homepage":"","size":61457,"stargazers_count":2650,"watchers_count":2650,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":610,"mirror_url":null,"open_issues_count":83,"forks":610,"open_issues":83,"watchers":2650,"default_branch":"release/2.2"}},"_links":{"self":{"href":"https://api.github.com/repos/bolt/bolt/pulls/5013"},"html":{"href":"https://github.com/bolt/bolt/pull/5013"},"issue":{"href":"https://api.github.com/repos/bolt/bolt/issues/5013"},"comments":{"href":"https://api.github.com/repos/bolt/bolt/issues/5013/comments"},"review_comments":{"href":"https://api.github.com/repos/bolt/bolt/pulls/5013/comments"},"review_comment":{"href":"https://api.github.com/repos/bolt/bolt/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bolt/bolt/pulls/5013/commits"},"statuses":{"href":"https://api.github.com/repos/bolt/bolt/statuses/0da3f9391168b77d54884fe9bb274554a737e5c9"}}}}