{"action":"created","comment":{"url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/comments/35627977","id":35627977,"diff_hunk":"@@ -127,13 +127,17 @@ def facet_field_aggregation_options(name)\n         def facet_query_aggregations\n           return {} unless blacklight_config\n \n-          blacklight_config.facet_fields.select { |_k, v| v.query }.each_with_object({}) do |(field_name, facet_field), hash|\n-            salient_facet_queries = facet_field.query.map { |_k, x| x[:fq] }\n-            items = []\n-            facet_queries.select { |k, _v| salient_facet_queries.include?(k) }.reject { |_value, hits| hits == 0 }.map do |value, hits|\n+          query_facet_fields = blacklight_config.facet_fields.select { |_k, v| v.query }\n+          query_facet_fields.each_with_object({}) do |(field_name, facet_field), hash|\n+            facet_query_params = facet_field.query.map { |_k, v| v[:fq] }\n+            response_facet_queries = facet_queries.dup\n+            response_facet_queries.select! { |k, _hits| facet_query_params.include?(k) }","path":"lib/europeana/blacklight/response/facets.rb","position":12,"original_position":12,"commit_id":"99fcdb108f0d30ed491783496cacc115a79c17a6","original_commit_id":"99fcdb108f0d30ed491783496cacc115a79c17a6","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Line is too long. [88/80]","created_at":"2015-07-28T09:10:16Z","updated_at":"2015-07-28T09:10:16Z","html_url":"https://github.com/europeana/europeana-blacklight/pull/10#discussion_r35627977","pull_request_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10","_links":{"self":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/comments/35627977"},"html":{"href":"https://github.com/europeana/europeana-blacklight/pull/10#discussion_r35627977"},"pull_request":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10"}}},"pull_request":{"url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10","id":40989868,"html_url":"https://github.com/europeana/europeana-blacklight/pull/10","diff_url":"https://github.com/europeana/europeana-blacklight/pull/10.diff","patch_url":"https://github.com/europeana/europeana-blacklight/pull/10.patch","issue_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/10","number":10,"state":"open","locked":false,"title":"Query facet fq options are hashes.","user":{"login":"rwd","id":218337,"avatar_url":"https://avatars.githubusercontent.com/u/218337?v=3","gravatar_id":"","url":"https://api.github.com/users/rwd","html_url":"https://github.com/rwd","followers_url":"https://api.github.com/users/rwd/followers","following_url":"https://api.github.com/users/rwd/following{/other_user}","gists_url":"https://api.github.com/users/rwd/gists{/gist_id}","starred_url":"https://api.github.com/users/rwd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rwd/subscriptions","organizations_url":"https://api.github.com/users/rwd/orgs","repos_url":"https://api.github.com/users/rwd/repos","events_url":"https://api.github.com/users/rwd/events{/privacy}","received_events_url":"https://api.github.com/users/rwd/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-07-28T09:10:13Z","updated_at":"2015-07-28T09:10:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b7cb11c41dd9a8d7fec77456c5836fbb6e38682b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10/commits","review_comments_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10/comments","review_comment_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/comments{/number}","comments_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/10/comments","statuses_url":"https://api.github.com/repos/europeana/europeana-blacklight/statuses/99fcdb108f0d30ed491783496cacc115a79c17a6","head":{"label":"europeana:query-facet-hash-fq","ref":"query-facet-hash-fq","sha":"99fcdb108f0d30ed491783496cacc115a79c17a6","user":{"login":"europeana","id":4570681,"avatar_url":"https://avatars.githubusercontent.com/u/4570681?v=3","gravatar_id":"","url":"https://api.github.com/users/europeana","html_url":"https://github.com/europeana","followers_url":"https://api.github.com/users/europeana/followers","following_url":"https://api.github.com/users/europeana/following{/other_user}","gists_url":"https://api.github.com/users/europeana/gists{/gist_id}","starred_url":"https://api.github.com/users/europeana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/europeana/subscriptions","organizations_url":"https://api.github.com/users/europeana/orgs","repos_url":"https://api.github.com/users/europeana/repos","events_url":"https://api.github.com/users/europeana/events{/privacy}","received_events_url":"https://api.github.com/users/europeana/received_events","type":"Organization","site_admin":false},"repo":{"id":33544713,"name":"europeana-blacklight","full_name":"europeana/europeana-blacklight","owner":{"login":"europeana","id":4570681,"avatar_url":"https://avatars.githubusercontent.com/u/4570681?v=3","gravatar_id":"","url":"https://api.github.com/users/europeana","html_url":"https://github.com/europeana","followers_url":"https://api.github.com/users/europeana/followers","following_url":"https://api.github.com/users/europeana/following{/other_user}","gists_url":"https://api.github.com/users/europeana/gists{/gist_id}","starred_url":"https://api.github.com/users/europeana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/europeana/subscriptions","organizations_url":"https://api.github.com/users/europeana/orgs","repos_url":"https://api.github.com/users/europeana/repos","events_url":"https://api.github.com/users/europeana/events{/privacy}","received_events_url":"https://api.github.com/users/europeana/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/europeana/europeana-blacklight","description":"Europeana REST API adapter for Blacklight","fork":false,"url":"https://api.github.com/repos/europeana/europeana-blacklight","forks_url":"https://api.github.com/repos/europeana/europeana-blacklight/forks","keys_url":"https://api.github.com/repos/europeana/europeana-blacklight/keys{/key_id}","collaborators_url":"https://api.github.com/repos/europeana/europeana-blacklight/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/europeana/europeana-blacklight/teams","hooks_url":"https://api.github.com/repos/europeana/europeana-blacklight/hooks","issue_events_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/events{/number}","events_url":"https://api.github.com/repos/europeana/europeana-blacklight/events","assignees_url":"https://api.github.com/repos/europeana/europeana-blacklight/assignees{/user}","branches_url":"https://api.github.com/repos/europeana/europeana-blacklight/branches{/branch}","tags_url":"https://api.github.com/repos/europeana/europeana-blacklight/tags","blobs_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/refs{/sha}","trees_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/trees{/sha}","statuses_url":"https://api.github.com/repos/europeana/europeana-blacklight/statuses/{sha}","languages_url":"https://api.github.com/repos/europeana/europeana-blacklight/languages","stargazers_url":"https://api.github.com/repos/europeana/europeana-blacklight/stargazers","contributors_url":"https://api.github.com/repos/europeana/europeana-blacklight/contributors","subscribers_url":"https://api.github.com/repos/europeana/europeana-blacklight/subscribers","subscription_url":"https://api.github.com/repos/europeana/europeana-blacklight/subscription","commits_url":"https://api.github.com/repos/europeana/europeana-blacklight/commits{/sha}","git_commits_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/commits{/sha}","comments_url":"https://api.github.com/repos/europeana/europeana-blacklight/comments{/number}","issue_comment_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/comments{/number}","contents_url":"https://api.github.com/repos/europeana/europeana-blacklight/contents/{+path}","compare_url":"https://api.github.com/repos/europeana/europeana-blacklight/compare/{base}...{head}","merges_url":"https://api.github.com/repos/europeana/europeana-blacklight/merges","archive_url":"https://api.github.com/repos/europeana/europeana-blacklight/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/europeana/europeana-blacklight/downloads","issues_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues{/number}","pulls_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls{/number}","milestones_url":"https://api.github.com/repos/europeana/europeana-blacklight/milestones{/number}","notifications_url":"https://api.github.com/repos/europeana/europeana-blacklight/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/europeana/europeana-blacklight/labels{/name}","releases_url":"https://api.github.com/repos/europeana/europeana-blacklight/releases{/id}","created_at":"2015-04-07T13:28:05Z","updated_at":"2015-05-07T14:44:44Z","pushed_at":"2015-07-28T09:10:13Z","git_url":"git://github.com/europeana/europeana-blacklight.git","ssh_url":"git@github.com:europeana/europeana-blacklight.git","clone_url":"https://github.com/europeana/europeana-blacklight.git","svn_url":"https://github.com/europeana/europeana-blacklight","homepage":null,"size":364,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"europeana:master","ref":"master","sha":"2f9705f0443ab3cd9539d267496b3554c083366c","user":{"login":"europeana","id":4570681,"avatar_url":"https://avatars.githubusercontent.com/u/4570681?v=3","gravatar_id":"","url":"https://api.github.com/users/europeana","html_url":"https://github.com/europeana","followers_url":"https://api.github.com/users/europeana/followers","following_url":"https://api.github.com/users/europeana/following{/other_user}","gists_url":"https://api.github.com/users/europeana/gists{/gist_id}","starred_url":"https://api.github.com/users/europeana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/europeana/subscriptions","organizations_url":"https://api.github.com/users/europeana/orgs","repos_url":"https://api.github.com/users/europeana/repos","events_url":"https://api.github.com/users/europeana/events{/privacy}","received_events_url":"https://api.github.com/users/europeana/received_events","type":"Organization","site_admin":false},"repo":{"id":33544713,"name":"europeana-blacklight","full_name":"europeana/europeana-blacklight","owner":{"login":"europeana","id":4570681,"avatar_url":"https://avatars.githubusercontent.com/u/4570681?v=3","gravatar_id":"","url":"https://api.github.com/users/europeana","html_url":"https://github.com/europeana","followers_url":"https://api.github.com/users/europeana/followers","following_url":"https://api.github.com/users/europeana/following{/other_user}","gists_url":"https://api.github.com/users/europeana/gists{/gist_id}","starred_url":"https://api.github.com/users/europeana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/europeana/subscriptions","organizations_url":"https://api.github.com/users/europeana/orgs","repos_url":"https://api.github.com/users/europeana/repos","events_url":"https://api.github.com/users/europeana/events{/privacy}","received_events_url":"https://api.github.com/users/europeana/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/europeana/europeana-blacklight","description":"Europeana REST API adapter for Blacklight","fork":false,"url":"https://api.github.com/repos/europeana/europeana-blacklight","forks_url":"https://api.github.com/repos/europeana/europeana-blacklight/forks","keys_url":"https://api.github.com/repos/europeana/europeana-blacklight/keys{/key_id}","collaborators_url":"https://api.github.com/repos/europeana/europeana-blacklight/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/europeana/europeana-blacklight/teams","hooks_url":"https://api.github.com/repos/europeana/europeana-blacklight/hooks","issue_events_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/events{/number}","events_url":"https://api.github.com/repos/europeana/europeana-blacklight/events","assignees_url":"https://api.github.com/repos/europeana/europeana-blacklight/assignees{/user}","branches_url":"https://api.github.com/repos/europeana/europeana-blacklight/branches{/branch}","tags_url":"https://api.github.com/repos/europeana/europeana-blacklight/tags","blobs_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/refs{/sha}","trees_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/trees{/sha}","statuses_url":"https://api.github.com/repos/europeana/europeana-blacklight/statuses/{sha}","languages_url":"https://api.github.com/repos/europeana/europeana-blacklight/languages","stargazers_url":"https://api.github.com/repos/europeana/europeana-blacklight/stargazers","contributors_url":"https://api.github.com/repos/europeana/europeana-blacklight/contributors","subscribers_url":"https://api.github.com/repos/europeana/europeana-blacklight/subscribers","subscription_url":"https://api.github.com/repos/europeana/europeana-blacklight/subscription","commits_url":"https://api.github.com/repos/europeana/europeana-blacklight/commits{/sha}","git_commits_url":"https://api.github.com/repos/europeana/europeana-blacklight/git/commits{/sha}","comments_url":"https://api.github.com/repos/europeana/europeana-blacklight/comments{/number}","issue_comment_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues/comments{/number}","contents_url":"https://api.github.com/repos/europeana/europeana-blacklight/contents/{+path}","compare_url":"https://api.github.com/repos/europeana/europeana-blacklight/compare/{base}...{head}","merges_url":"https://api.github.com/repos/europeana/europeana-blacklight/merges","archive_url":"https://api.github.com/repos/europeana/europeana-blacklight/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/europeana/europeana-blacklight/downloads","issues_url":"https://api.github.com/repos/europeana/europeana-blacklight/issues{/number}","pulls_url":"https://api.github.com/repos/europeana/europeana-blacklight/pulls{/number}","milestones_url":"https://api.github.com/repos/europeana/europeana-blacklight/milestones{/number}","notifications_url":"https://api.github.com/repos/europeana/europeana-blacklight/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/europeana/europeana-blacklight/labels{/name}","releases_url":"https://api.github.com/repos/europeana/europeana-blacklight/releases{/id}","created_at":"2015-04-07T13:28:05Z","updated_at":"2015-05-07T14:44:44Z","pushed_at":"2015-07-28T09:10:13Z","git_url":"git://github.com/europeana/europeana-blacklight.git","ssh_url":"git@github.com:europeana/europeana-blacklight.git","clone_url":"https://github.com/europeana/europeana-blacklight.git","svn_url":"https://github.com/europeana/europeana-blacklight","homepage":null,"size":364,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10"},"html":{"href":"https://github.com/europeana/europeana-blacklight/pull/10"},"issue":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/issues/10"},"comments":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/issues/10/comments"},"review_comments":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10/comments"},"review_comment":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/pulls/10/commits"},"statuses":{"href":"https://api.github.com/repos/europeana/europeana-blacklight/statuses/99fcdb108f0d30ed491783496cacc115a79c17a6"}}}}