{"action":"opened","number":8323,"pull_request":{"url":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323","id":37190080,"html_url":"https://github.com/woothemes/woocommerce/pull/8323","diff_url":"https://github.com/woothemes/woocommerce/pull/8323.diff","patch_url":"https://github.com/woothemes/woocommerce/pull/8323.patch","issue_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8323","number":8323,"state":"open","locked":false,"title":"Switch the ajax json_search_* functions to check for the edit_shop_orders capability","user":{"login":"justinshreve","id":689165,"avatar_url":"https://avatars.githubusercontent.com/u/689165?v=3","gravatar_id":"","url":"https://api.github.com/users/justinshreve","html_url":"https://github.com/justinshreve","followers_url":"https://api.github.com/users/justinshreve/followers","following_url":"https://api.github.com/users/justinshreve/following{/other_user}","gists_url":"https://api.github.com/users/justinshreve/gists{/gist_id}","starred_url":"https://api.github.com/users/justinshreve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinshreve/subscriptions","organizations_url":"https://api.github.com/users/justinshreve/orgs","repos_url":"https://api.github.com/users/justinshreve/repos","events_url":"https://api.github.com/users/justinshreve/events{/privacy}","received_events_url":"https://api.github.com/users/justinshreve/received_events","type":"User","site_admin":false},"body":"Both `json_search_products` and `json_search_downloadable_products_and_variations` are checking the `edit_products` capability check, while other `json_search_*` functions like `json_search_customers` are using `edit_shop_orders`. \r\n\r\n`edit_shop_orders` make more sense and allows users to still search for products in the order form without managing them.\r\n\r\nFixes #8321","created_at":"2015-06-08T20:01:57Z","updated_at":"2015-06-08T20:01:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":{"login":"justinshreve","id":689165,"avatar_url":"https://avatars.githubusercontent.com/u/689165?v=3","gravatar_id":"","url":"https://api.github.com/users/justinshreve","html_url":"https://github.com/justinshreve","followers_url":"https://api.github.com/users/justinshreve/followers","following_url":"https://api.github.com/users/justinshreve/following{/other_user}","gists_url":"https://api.github.com/users/justinshreve/gists{/gist_id}","starred_url":"https://api.github.com/users/justinshreve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinshreve/subscriptions","organizations_url":"https://api.github.com/users/justinshreve/orgs","repos_url":"https://api.github.com/users/justinshreve/repos","events_url":"https://api.github.com/users/justinshreve/events{/privacy}","received_events_url":"https://api.github.com/users/justinshreve/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323/commits","review_comments_url":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323/comments","review_comment_url":"https://api.github.com/repos/woothemes/woocommerce/pulls/comments{/number}","comments_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8323/comments","statuses_url":"https://api.github.com/repos/woothemes/woocommerce/statuses/c8dc6b447d3c9306549f6093c587874dbe870087","head":{"label":"justinshreve:json-search-permissions-check-8321","ref":"json-search-permissions-check-8321","sha":"c8dc6b447d3c9306549f6093c587874dbe870087","user":{"login":"justinshreve","id":689165,"avatar_url":"https://avatars.githubusercontent.com/u/689165?v=3","gravatar_id":"","url":"https://api.github.com/users/justinshreve","html_url":"https://github.com/justinshreve","followers_url":"https://api.github.com/users/justinshreve/followers","following_url":"https://api.github.com/users/justinshreve/following{/other_user}","gists_url":"https://api.github.com/users/justinshreve/gists{/gist_id}","starred_url":"https://api.github.com/users/justinshreve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinshreve/subscriptions","organizations_url":"https://api.github.com/users/justinshreve/orgs","repos_url":"https://api.github.com/users/justinshreve/repos","events_url":"https://api.github.com/users/justinshreve/events{/privacy}","received_events_url":"https://api.github.com/users/justinshreve/received_events","type":"User","site_admin":false},"repo":{"id":36830592,"name":"woocommerce","full_name":"justinshreve/woocommerce","owner":{"login":"justinshreve","id":689165,"avatar_url":"https://avatars.githubusercontent.com/u/689165?v=3","gravatar_id":"","url":"https://api.github.com/users/justinshreve","html_url":"https://github.com/justinshreve","followers_url":"https://api.github.com/users/justinshreve/followers","following_url":"https://api.github.com/users/justinshreve/following{/other_user}","gists_url":"https://api.github.com/users/justinshreve/gists{/gist_id}","starred_url":"https://api.github.com/users/justinshreve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinshreve/subscriptions","organizations_url":"https://api.github.com/users/justinshreve/orgs","repos_url":"https://api.github.com/users/justinshreve/repos","events_url":"https://api.github.com/users/justinshreve/events{/privacy}","received_events_url":"https://api.github.com/users/justinshreve/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/justinshreve/woocommerce","description":"An open source eCommerce plugin for WordPress created by WooThemes.","fork":true,"url":"https://api.github.com/repos/justinshreve/woocommerce","forks_url":"https://api.github.com/repos/justinshreve/woocommerce/forks","keys_url":"https://api.github.com/repos/justinshreve/woocommerce/keys{/key_id}","collaborators_url":"https://api.github.com/repos/justinshreve/woocommerce/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/justinshreve/woocommerce/teams","hooks_url":"https://api.github.com/repos/justinshreve/woocommerce/hooks","issue_events_url":"https://api.github.com/repos/justinshreve/woocommerce/issues/events{/number}","events_url":"https://api.github.com/repos/justinshreve/woocommerce/events","assignees_url":"https://api.github.com/repos/justinshreve/woocommerce/assignees{/user}","branches_url":"https://api.github.com/repos/justinshreve/woocommerce/branches{/branch}","tags_url":"https://api.github.com/repos/justinshreve/woocommerce/tags","blobs_url":"https://api.github.com/repos/justinshreve/woocommerce/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/justinshreve/woocommerce/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/justinshreve/woocommerce/git/refs{/sha}","trees_url":"https://api.github.com/repos/justinshreve/woocommerce/git/trees{/sha}","statuses_url":"https://api.github.com/repos/justinshreve/woocommerce/statuses/{sha}","languages_url":"https://api.github.com/repos/justinshreve/woocommerce/languages","stargazers_url":"https://api.github.com/repos/justinshreve/woocommerce/stargazers","contributors_url":"https://api.github.com/repos/justinshreve/woocommerce/contributors","subscribers_url":"https://api.github.com/repos/justinshreve/woocommerce/subscribers","subscription_url":"https://api.github.com/repos/justinshreve/woocommerce/subscription","commits_url":"https://api.github.com/repos/justinshreve/woocommerce/commits{/sha}","git_commits_url":"https://api.github.com/repos/justinshreve/woocommerce/git/commits{/sha}","comments_url":"https://api.github.com/repos/justinshreve/woocommerce/comments{/number}","issue_comment_url":"https://api.github.com/repos/justinshreve/woocommerce/issues/comments{/number}","contents_url":"https://api.github.com/repos/justinshreve/woocommerce/contents/{+path}","compare_url":"https://api.github.com/repos/justinshreve/woocommerce/compare/{base}...{head}","merges_url":"https://api.github.com/repos/justinshreve/woocommerce/merges","archive_url":"https://api.github.com/repos/justinshreve/woocommerce/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/justinshreve/woocommerce/downloads","issues_url":"https://api.github.com/repos/justinshreve/woocommerce/issues{/number}","pulls_url":"https://api.github.com/repos/justinshreve/woocommerce/pulls{/number}","milestones_url":"https://api.github.com/repos/justinshreve/woocommerce/milestones{/number}","notifications_url":"https://api.github.com/repos/justinshreve/woocommerce/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/justinshreve/woocommerce/labels{/name}","releases_url":"https://api.github.com/repos/justinshreve/woocommerce/releases{/id}","created_at":"2015-06-03T21:05:53Z","updated_at":"2015-06-04T13:58:01Z","pushed_at":"2015-06-08T19:56:39Z","git_url":"git://github.com/justinshreve/woocommerce.git","ssh_url":"git@github.com:justinshreve/woocommerce.git","clone_url":"https://github.com/justinshreve/woocommerce.git","svn_url":"https://github.com/justinshreve/woocommerce","homepage":"http://www.woothemes.com/woocommerce/","size":102133,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"woothemes:master","ref":"master","sha":"55efdc5077fec6904bc56caf92fd9589e762800f","user":{"login":"woothemes","id":473596,"avatar_url":"https://avatars.githubusercontent.com/u/473596?v=3","gravatar_id":"","url":"https://api.github.com/users/woothemes","html_url":"https://github.com/woothemes","followers_url":"https://api.github.com/users/woothemes/followers","following_url":"https://api.github.com/users/woothemes/following{/other_user}","gists_url":"https://api.github.com/users/woothemes/gists{/gist_id}","starred_url":"https://api.github.com/users/woothemes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woothemes/subscriptions","organizations_url":"https://api.github.com/users/woothemes/orgs","repos_url":"https://api.github.com/users/woothemes/repos","events_url":"https://api.github.com/users/woothemes/events{/privacy}","received_events_url":"https://api.github.com/users/woothemes/received_events","type":"Organization","site_admin":false},"repo":{"id":2179920,"name":"woocommerce","full_name":"woothemes/woocommerce","owner":{"login":"woothemes","id":473596,"avatar_url":"https://avatars.githubusercontent.com/u/473596?v=3","gravatar_id":"","url":"https://api.github.com/users/woothemes","html_url":"https://github.com/woothemes","followers_url":"https://api.github.com/users/woothemes/followers","following_url":"https://api.github.com/users/woothemes/following{/other_user}","gists_url":"https://api.github.com/users/woothemes/gists{/gist_id}","starred_url":"https://api.github.com/users/woothemes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woothemes/subscriptions","organizations_url":"https://api.github.com/users/woothemes/orgs","repos_url":"https://api.github.com/users/woothemes/repos","events_url":"https://api.github.com/users/woothemes/events{/privacy}","received_events_url":"https://api.github.com/users/woothemes/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/woothemes/woocommerce","description":"An open source eCommerce plugin for WordPress created by WooThemes.","fork":false,"url":"https://api.github.com/repos/woothemes/woocommerce","forks_url":"https://api.github.com/repos/woothemes/woocommerce/forks","keys_url":"https://api.github.com/repos/woothemes/woocommerce/keys{/key_id}","collaborators_url":"https://api.github.com/repos/woothemes/woocommerce/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/woothemes/woocommerce/teams","hooks_url":"https://api.github.com/repos/woothemes/woocommerce/hooks","issue_events_url":"https://api.github.com/repos/woothemes/woocommerce/issues/events{/number}","events_url":"https://api.github.com/repos/woothemes/woocommerce/events","assignees_url":"https://api.github.com/repos/woothemes/woocommerce/assignees{/user}","branches_url":"https://api.github.com/repos/woothemes/woocommerce/branches{/branch}","tags_url":"https://api.github.com/repos/woothemes/woocommerce/tags","blobs_url":"https://api.github.com/repos/woothemes/woocommerce/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/woothemes/woocommerce/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/woothemes/woocommerce/git/refs{/sha}","trees_url":"https://api.github.com/repos/woothemes/woocommerce/git/trees{/sha}","statuses_url":"https://api.github.com/repos/woothemes/woocommerce/statuses/{sha}","languages_url":"https://api.github.com/repos/woothemes/woocommerce/languages","stargazers_url":"https://api.github.com/repos/woothemes/woocommerce/stargazers","contributors_url":"https://api.github.com/repos/woothemes/woocommerce/contributors","subscribers_url":"https://api.github.com/repos/woothemes/woocommerce/subscribers","subscription_url":"https://api.github.com/repos/woothemes/woocommerce/subscription","commits_url":"https://api.github.com/repos/woothemes/woocommerce/commits{/sha}","git_commits_url":"https://api.github.com/repos/woothemes/woocommerce/git/commits{/sha}","comments_url":"https://api.github.com/repos/woothemes/woocommerce/comments{/number}","issue_comment_url":"https://api.github.com/repos/woothemes/woocommerce/issues/comments{/number}","contents_url":"https://api.github.com/repos/woothemes/woocommerce/contents/{+path}","compare_url":"https://api.github.com/repos/woothemes/woocommerce/compare/{base}...{head}","merges_url":"https://api.github.com/repos/woothemes/woocommerce/merges","archive_url":"https://api.github.com/repos/woothemes/woocommerce/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/woothemes/woocommerce/downloads","issues_url":"https://api.github.com/repos/woothemes/woocommerce/issues{/number}","pulls_url":"https://api.github.com/repos/woothemes/woocommerce/pulls{/number}","milestones_url":"https://api.github.com/repos/woothemes/woocommerce/milestones{/number}","notifications_url":"https://api.github.com/repos/woothemes/woocommerce/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/woothemes/woocommerce/labels{/name}","releases_url":"https://api.github.com/repos/woothemes/woocommerce/releases{/id}","created_at":"2011-08-09T15:12:11Z","updated_at":"2015-06-08T19:18:14Z","pushed_at":"2015-06-08T20:01:57Z","git_url":"git://github.com/woothemes/woocommerce.git","ssh_url":"git@github.com:woothemes/woocommerce.git","clone_url":"https://github.com/woothemes/woocommerce.git","svn_url":"https://github.com/woothemes/woocommerce","homepage":"http://www.woothemes.com/woocommerce/","size":131087,"stargazers_count":2085,"watchers_count":2085,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1625,"mirror_url":null,"open_issues_count":37,"forks":1625,"open_issues":37,"watchers":2085,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323"},"html":{"href":"https://github.com/woothemes/woocommerce/pull/8323"},"issue":{"href":"https://api.github.com/repos/woothemes/woocommerce/issues/8323"},"comments":{"href":"https://api.github.com/repos/woothemes/woocommerce/issues/8323/comments"},"review_comments":{"href":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323/comments"},"review_comment":{"href":"https://api.github.com/repos/woothemes/woocommerce/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/woothemes/woocommerce/pulls/8323/commits"},"statuses":{"href":"https://api.github.com/repos/woothemes/woocommerce/statuses/c8dc6b447d3c9306549f6093c587874dbe870087"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":2,"deletions":2,"changed_files":1}}