{"action":"closed","number":15,"pull_request":{"url":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15","id":45565655,"html_url":"https://github.com/jpmckinney/image-proxy/pull/15","diff_url":"https://github.com/jpmckinney/image-proxy/pull/15.diff","patch_url":"https://github.com/jpmckinney/image-proxy/pull/15.patch","issue_url":"https://api.github.com/repos/jpmckinney/image-proxy/issues/15","number":15,"state":"closed","locked":false,"title":"Send an 'Accept' header in the image request","user":{"login":"chrismytton","id":22996,"avatar_url":"https://avatars.githubusercontent.com/u/22996?v=3","gravatar_id":"","url":"https://api.github.com/users/chrismytton","html_url":"https://github.com/chrismytton","followers_url":"https://api.github.com/users/chrismytton/followers","following_url":"https://api.github.com/users/chrismytton/following{/other_user}","gists_url":"https://api.github.com/users/chrismytton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrismytton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrismytton/subscriptions","organizations_url":"https://api.github.com/users/chrismytton/orgs","repos_url":"https://api.github.com/users/chrismytton/repos","events_url":"https://api.github.com/users/chrismytton/events{/privacy}","received_events_url":"https://api.github.com/users/chrismytton/received_events","type":"User","site_admin":false},"body":"Some urls, e.g. this one - http://www.congreso.gob.gt/manager/images/69DBC2D6-2EE6-3EA7-411F-07C91997560D.jpg, don't respond correctly if there's no `Accept` header in the request.\r\n\r\nhttps://everypolitician-image-proxy.herokuapp.com/http%3A%2F%2Fwww.congreso.gob.gt%2Fmanager%2Fimages%2F69DBC2D6-2EE6-3EA7-411F-07C91997560D.jpg/140/140.jpg\r\n\r\nThis change adds an `Accept: image/*` header to each request for external images.\r\n\r\nI'm not 100% sure that this is the correct and/or best thing to be doing, but it certainly fixes it for the specific case of images on www.congreso.gob.gt.","created_at":"2015-09-21T15:51:36Z","updated_at":"2015-09-21T23:46:57Z","closed_at":"2015-09-21T23:46:57Z","merged_at":"2015-09-21T23:46:57Z","merge_commit_sha":"0cf6f47223482d3da7c0e3ba6b7fed17fa50987e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15/commits","review_comments_url":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15/comments","review_comment_url":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jpmckinney/image-proxy/issues/15/comments","statuses_url":"https://api.github.com/repos/jpmckinney/image-proxy/statuses/a94de21a9051530d49bd3a524d0d933cf68ce633","head":{"label":"mysociety:accept-header-in-request","ref":"accept-header-in-request","sha":"a94de21a9051530d49bd3a524d0d933cf68ce633","user":{"login":"mysociety","id":141338,"avatar_url":"https://avatars.githubusercontent.com/u/141338?v=3","gravatar_id":"","url":"https://api.github.com/users/mysociety","html_url":"https://github.com/mysociety","followers_url":"https://api.github.com/users/mysociety/followers","following_url":"https://api.github.com/users/mysociety/following{/other_user}","gists_url":"https://api.github.com/users/mysociety/gists{/gist_id}","starred_url":"https://api.github.com/users/mysociety/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mysociety/subscriptions","organizations_url":"https://api.github.com/users/mysociety/orgs","repos_url":"https://api.github.com/users/mysociety/repos","events_url":"https://api.github.com/users/mysociety/events{/privacy}","received_events_url":"https://api.github.com/users/mysociety/received_events","type":"Organization","site_admin":false},"repo":{"id":24452241,"name":"image-proxy","full_name":"mysociety/image-proxy","owner":{"login":"mysociety","id":141338,"avatar_url":"https://avatars.githubusercontent.com/u/141338?v=3","gravatar_id":"","url":"https://api.github.com/users/mysociety","html_url":"https://github.com/mysociety","followers_url":"https://api.github.com/users/mysociety/followers","following_url":"https://api.github.com/users/mysociety/following{/other_user}","gists_url":"https://api.github.com/users/mysociety/gists{/gist_id}","starred_url":"https://api.github.com/users/mysociety/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mysociety/subscriptions","organizations_url":"https://api.github.com/users/mysociety/orgs","repos_url":"https://api.github.com/users/mysociety/repos","events_url":"https://api.github.com/users/mysociety/events{/privacy}","received_events_url":"https://api.github.com/users/mysociety/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mysociety/image-proxy","description":"An image proxy using the Express Node.js framework","fork":true,"url":"https://api.github.com/repos/mysociety/image-proxy","forks_url":"https://api.github.com/repos/mysociety/image-proxy/forks","keys_url":"https://api.github.com/repos/mysociety/image-proxy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mysociety/image-proxy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mysociety/image-proxy/teams","hooks_url":"https://api.github.com/repos/mysociety/image-proxy/hooks","issue_events_url":"https://api.github.com/repos/mysociety/image-proxy/issues/events{/number}","events_url":"https://api.github.com/repos/mysociety/image-proxy/events","assignees_url":"https://api.github.com/repos/mysociety/image-proxy/assignees{/user}","branches_url":"https://api.github.com/repos/mysociety/image-proxy/branches{/branch}","tags_url":"https://api.github.com/repos/mysociety/image-proxy/tags","blobs_url":"https://api.github.com/repos/mysociety/image-proxy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mysociety/image-proxy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mysociety/image-proxy/git/refs{/sha}","trees_url":"https://api.github.com/repos/mysociety/image-proxy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mysociety/image-proxy/statuses/{sha}","languages_url":"https://api.github.com/repos/mysociety/image-proxy/languages","stargazers_url":"https://api.github.com/repos/mysociety/image-proxy/stargazers","contributors_url":"https://api.github.com/repos/mysociety/image-proxy/contributors","subscribers_url":"https://api.github.com/repos/mysociety/image-proxy/subscribers","subscription_url":"https://api.github.com/repos/mysociety/image-proxy/subscription","commits_url":"https://api.github.com/repos/mysociety/image-proxy/commits{/sha}","git_commits_url":"https://api.github.com/repos/mysociety/image-proxy/git/commits{/sha}","comments_url":"https://api.github.com/repos/mysociety/image-proxy/comments{/number}","issue_comment_url":"https://api.github.com/repos/mysociety/image-proxy/issues/comments{/number}","contents_url":"https://api.github.com/repos/mysociety/image-proxy/contents/{+path}","compare_url":"https://api.github.com/repos/mysociety/image-proxy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mysociety/image-proxy/merges","archive_url":"https://api.github.com/repos/mysociety/image-proxy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mysociety/image-proxy/downloads","issues_url":"https://api.github.com/repos/mysociety/image-proxy/issues{/number}","pulls_url":"https://api.github.com/repos/mysociety/image-proxy/pulls{/number}","milestones_url":"https://api.github.com/repos/mysociety/image-proxy/milestones{/number}","notifications_url":"https://api.github.com/repos/mysociety/image-proxy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mysociety/image-proxy/labels{/name}","releases_url":"https://api.github.com/repos/mysociety/image-proxy/releases{/id}","created_at":"2014-09-25T09:36:22Z","updated_at":"2015-03-11T12:50:18Z","pushed_at":"2015-09-21T15:49:29Z","git_url":"git://github.com/mysociety/image-proxy.git","ssh_url":"git@github.com:mysociety/image-proxy.git","clone_url":"https://github.com/mysociety/image-proxy.git","svn_url":"https://github.com/mysociety/image-proxy","homepage":null,"size":3881,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"jpmckinney:master","ref":"master","sha":"b6ef772e3a8eb83c024db628c132086fe2a7b809","user":{"login":"jpmckinney","id":26463,"avatar_url":"https://avatars.githubusercontent.com/u/26463?v=3","gravatar_id":"","url":"https://api.github.com/users/jpmckinney","html_url":"https://github.com/jpmckinney","followers_url":"https://api.github.com/users/jpmckinney/followers","following_url":"https://api.github.com/users/jpmckinney/following{/other_user}","gists_url":"https://api.github.com/users/jpmckinney/gists{/gist_id}","starred_url":"https://api.github.com/users/jpmckinney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpmckinney/subscriptions","organizations_url":"https://api.github.com/users/jpmckinney/orgs","repos_url":"https://api.github.com/users/jpmckinney/repos","events_url":"https://api.github.com/users/jpmckinney/events{/privacy}","received_events_url":"https://api.github.com/users/jpmckinney/received_events","type":"User","site_admin":false},"repo":{"id":8240648,"name":"image-proxy","full_name":"jpmckinney/image-proxy","owner":{"login":"jpmckinney","id":26463,"avatar_url":"https://avatars.githubusercontent.com/u/26463?v=3","gravatar_id":"","url":"https://api.github.com/users/jpmckinney","html_url":"https://github.com/jpmckinney","followers_url":"https://api.github.com/users/jpmckinney/followers","following_url":"https://api.github.com/users/jpmckinney/following{/other_user}","gists_url":"https://api.github.com/users/jpmckinney/gists{/gist_id}","starred_url":"https://api.github.com/users/jpmckinney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpmckinney/subscriptions","organizations_url":"https://api.github.com/users/jpmckinney/orgs","repos_url":"https://api.github.com/users/jpmckinney/repos","events_url":"https://api.github.com/users/jpmckinney/events{/privacy}","received_events_url":"https://api.github.com/users/jpmckinney/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jpmckinney/image-proxy","description":"An image proxy using the Express Node.js framework","fork":false,"url":"https://api.github.com/repos/jpmckinney/image-proxy","forks_url":"https://api.github.com/repos/jpmckinney/image-proxy/forks","keys_url":"https://api.github.com/repos/jpmckinney/image-proxy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jpmckinney/image-proxy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jpmckinney/image-proxy/teams","hooks_url":"https://api.github.com/repos/jpmckinney/image-proxy/hooks","issue_events_url":"https://api.github.com/repos/jpmckinney/image-proxy/issues/events{/number}","events_url":"https://api.github.com/repos/jpmckinney/image-proxy/events","assignees_url":"https://api.github.com/repos/jpmckinney/image-proxy/assignees{/user}","branches_url":"https://api.github.com/repos/jpmckinney/image-proxy/branches{/branch}","tags_url":"https://api.github.com/repos/jpmckinney/image-proxy/tags","blobs_url":"https://api.github.com/repos/jpmckinney/image-proxy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jpmckinney/image-proxy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jpmckinney/image-proxy/git/refs{/sha}","trees_url":"https://api.github.com/repos/jpmckinney/image-proxy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jpmckinney/image-proxy/statuses/{sha}","languages_url":"https://api.github.com/repos/jpmckinney/image-proxy/languages","stargazers_url":"https://api.github.com/repos/jpmckinney/image-proxy/stargazers","contributors_url":"https://api.github.com/repos/jpmckinney/image-proxy/contributors","subscribers_url":"https://api.github.com/repos/jpmckinney/image-proxy/subscribers","subscription_url":"https://api.github.com/repos/jpmckinney/image-proxy/subscription","commits_url":"https://api.github.com/repos/jpmckinney/image-proxy/commits{/sha}","git_commits_url":"https://api.github.com/repos/jpmckinney/image-proxy/git/commits{/sha}","comments_url":"https://api.github.com/repos/jpmckinney/image-proxy/comments{/number}","issue_comment_url":"https://api.github.com/repos/jpmckinney/image-proxy/issues/comments{/number}","contents_url":"https://api.github.com/repos/jpmckinney/image-proxy/contents/{+path}","compare_url":"https://api.github.com/repos/jpmckinney/image-proxy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jpmckinney/image-proxy/merges","archive_url":"https://api.github.com/repos/jpmckinney/image-proxy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jpmckinney/image-proxy/downloads","issues_url":"https://api.github.com/repos/jpmckinney/image-proxy/issues{/number}","pulls_url":"https://api.github.com/repos/jpmckinney/image-proxy/pulls{/number}","milestones_url":"https://api.github.com/repos/jpmckinney/image-proxy/milestones{/number}","notifications_url":"https://api.github.com/repos/jpmckinney/image-proxy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jpmckinney/image-proxy/labels{/name}","releases_url":"https://api.github.com/repos/jpmckinney/image-proxy/releases{/id}","created_at":"2013-02-16T19:44:17Z","updated_at":"2015-08-15T16:32:36Z","pushed_at":"2015-09-21T23:46:57Z","git_url":"git://github.com/jpmckinney/image-proxy.git","ssh_url":"git@github.com:jpmckinney/image-proxy.git","clone_url":"https://github.com/jpmckinney/image-proxy.git","svn_url":"https://github.com/jpmckinney/image-proxy","homepage":null,"size":4049,"stargazers_count":21,"watchers_count":21,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":14,"mirror_url":null,"open_issues_count":0,"forks":14,"open_issues":0,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15"},"html":{"href":"https://github.com/jpmckinney/image-proxy/pull/15"},"issue":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/issues/15"},"comments":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/issues/15/comments"},"review_comments":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15/comments"},"review_comment":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/pulls/15/commits"},"statuses":{"href":"https://api.github.com/repos/jpmckinney/image-proxy/statuses/a94de21a9051530d49bd3a524d0d933cf68ce633"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"jpmckinney","id":26463,"avatar_url":"https://avatars.githubusercontent.com/u/26463?v=3","gravatar_id":"","url":"https://api.github.com/users/jpmckinney","html_url":"https://github.com/jpmckinney","followers_url":"https://api.github.com/users/jpmckinney/followers","following_url":"https://api.github.com/users/jpmckinney/following{/other_user}","gists_url":"https://api.github.com/users/jpmckinney/gists{/gist_id}","starred_url":"https://api.github.com/users/jpmckinney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpmckinney/subscriptions","organizations_url":"https://api.github.com/users/jpmckinney/orgs","repos_url":"https://api.github.com/users/jpmckinney/repos","events_url":"https://api.github.com/users/jpmckinney/events{/privacy}","received_events_url":"https://api.github.com/users/jpmckinney/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"commits":1,"additions":20,"deletions":1,"changed_files":2}}