{"action":"created","comment":{"url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/comments/36541251","id":36541251,"diff_hunk":"@@ -237,7 +237,7 @@ protected function generateUploadParts(EntityBodyInterface $body)\n         $uploadContext = new UploadPartContext($this->partSize, $body->ftell());\n \n         // Read the data from the streamed body in 1MB chunks\n-        while ($data = $body->read(min($this->partSize, Size::MB))) {\n+        while (strlen($data = $body->read(min($this->partSize, Size::MB))) > 0) {","path":"src/Aws/Glacier/Model/MultipartUpload/UploadPartGenerator.php","position":5,"original_position":5,"commit_id":"0335272f744cf175e368a9f2d508c5049bcc4f24","original_commit_id":"0335272f744cf175e368a9f2d508c5049bcc4f24","user":{"login":"mtdowling","id":190930,"avatar_url":"https://avatars.githubusercontent.com/u/190930?v=3","gravatar_id":"","url":"https://api.github.com/users/mtdowling","html_url":"https://github.com/mtdowling","followers_url":"https://api.github.com/users/mtdowling/followers","following_url":"https://api.github.com/users/mtdowling/following{/other_user}","gists_url":"https://api.github.com/users/mtdowling/gists{/gist_id}","starred_url":"https://api.github.com/users/mtdowling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mtdowling/subscriptions","organizations_url":"https://api.github.com/users/mtdowling/orgs","repos_url":"https://api.github.com/users/mtdowling/repos","events_url":"https://api.github.com/users/mtdowling/events{/privacy}","received_events_url":"https://api.github.com/users/mtdowling/received_events","type":"User","site_admin":false},"body":"I think we should make this more readable by moving the assignment and conditions to their own lines.","created_at":"2015-08-07T17:32:13Z","updated_at":"2015-08-07T17:32:13Z","html_url":"https://github.com/aws/aws-sdk-php/pull/718#discussion_r36541251","pull_request_url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718","_links":{"self":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/comments/36541251"},"html":{"href":"https://github.com/aws/aws-sdk-php/pull/718#discussion_r36541251"},"pull_request":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718"}}},"pull_request":{"url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718","id":41835451,"html_url":"https://github.com/aws/aws-sdk-php/pull/718","diff_url":"https://github.com/aws/aws-sdk-php/pull/718.diff","patch_url":"https://github.com/aws/aws-sdk-php/pull/718.patch","issue_url":"https://api.github.com/repos/aws/aws-sdk-php/issues/718","number":718,"state":"open","locked":false,"title":"Allow the uploading of falsy strings to glacier","user":{"login":"jeskew","id":705500,"avatar_url":"https://avatars.githubusercontent.com/u/705500?v=3","gravatar_id":"","url":"https://api.github.com/users/jeskew","html_url":"https://github.com/jeskew","followers_url":"https://api.github.com/users/jeskew/followers","following_url":"https://api.github.com/users/jeskew/following{/other_user}","gists_url":"https://api.github.com/users/jeskew/gists{/gist_id}","starred_url":"https://api.github.com/users/jeskew/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeskew/subscriptions","organizations_url":"https://api.github.com/users/jeskew/orgs","repos_url":"https://api.github.com/users/jeskew/repos","events_url":"https://api.github.com/users/jeskew/events{/privacy}","received_events_url":"https://api.github.com/users/jeskew/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-08-06T21:11:53Z","updated_at":"2015-08-07T17:32:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"18e56b7037544c0ed8d389138d21f50af5edbb13","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718/commits","review_comments_url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718/comments","review_comment_url":"https://api.github.com/repos/aws/aws-sdk-php/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aws/aws-sdk-php/issues/718/comments","statuses_url":"https://api.github.com/repos/aws/aws-sdk-php/statuses/0335272f744cf175e368a9f2d508c5049bcc4f24","head":{"label":"jeskew:fix/upload-falsy-payloads-to-glacier","ref":"fix/upload-falsy-payloads-to-glacier","sha":"0335272f744cf175e368a9f2d508c5049bcc4f24","user":{"login":"jeskew","id":705500,"avatar_url":"https://avatars.githubusercontent.com/u/705500?v=3","gravatar_id":"","url":"https://api.github.com/users/jeskew","html_url":"https://github.com/jeskew","followers_url":"https://api.github.com/users/jeskew/followers","following_url":"https://api.github.com/users/jeskew/following{/other_user}","gists_url":"https://api.github.com/users/jeskew/gists{/gist_id}","starred_url":"https://api.github.com/users/jeskew/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeskew/subscriptions","organizations_url":"https://api.github.com/users/jeskew/orgs","repos_url":"https://api.github.com/users/jeskew/repos","events_url":"https://api.github.com/users/jeskew/events{/privacy}","received_events_url":"https://api.github.com/users/jeskew/received_events","type":"User","site_admin":false},"repo":{"id":37143307,"name":"aws-sdk-php","full_name":"jeskew/aws-sdk-php","owner":{"login":"jeskew","id":705500,"avatar_url":"https://avatars.githubusercontent.com/u/705500?v=3","gravatar_id":"","url":"https://api.github.com/users/jeskew","html_url":"https://github.com/jeskew","followers_url":"https://api.github.com/users/jeskew/followers","following_url":"https://api.github.com/users/jeskew/following{/other_user}","gists_url":"https://api.github.com/users/jeskew/gists{/gist_id}","starred_url":"https://api.github.com/users/jeskew/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeskew/subscriptions","organizations_url":"https://api.github.com/users/jeskew/orgs","repos_url":"https://api.github.com/users/jeskew/repos","events_url":"https://api.github.com/users/jeskew/events{/privacy}","received_events_url":"https://api.github.com/users/jeskew/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jeskew/aws-sdk-php","description":"Official repository of the AWS SDK for PHP (@awsforphp)","fork":true,"url":"https://api.github.com/repos/jeskew/aws-sdk-php","forks_url":"https://api.github.com/repos/jeskew/aws-sdk-php/forks","keys_url":"https://api.github.com/repos/jeskew/aws-sdk-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jeskew/aws-sdk-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jeskew/aws-sdk-php/teams","hooks_url":"https://api.github.com/repos/jeskew/aws-sdk-php/hooks","issue_events_url":"https://api.github.com/repos/jeskew/aws-sdk-php/issues/events{/number}","events_url":"https://api.github.com/repos/jeskew/aws-sdk-php/events","assignees_url":"https://api.github.com/repos/jeskew/aws-sdk-php/assignees{/user}","branches_url":"https://api.github.com/repos/jeskew/aws-sdk-php/branches{/branch}","tags_url":"https://api.github.com/repos/jeskew/aws-sdk-php/tags","blobs_url":"https://api.github.com/repos/jeskew/aws-sdk-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jeskew/aws-sdk-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jeskew/aws-sdk-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/jeskew/aws-sdk-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jeskew/aws-sdk-php/statuses/{sha}","languages_url":"https://api.github.com/repos/jeskew/aws-sdk-php/languages","stargazers_url":"https://api.github.com/repos/jeskew/aws-sdk-php/stargazers","contributors_url":"https://api.github.com/repos/jeskew/aws-sdk-php/contributors","subscribers_url":"https://api.github.com/repos/jeskew/aws-sdk-php/subscribers","subscription_url":"https://api.github.com/repos/jeskew/aws-sdk-php/subscription","commits_url":"https://api.github.com/repos/jeskew/aws-sdk-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/jeskew/aws-sdk-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/jeskew/aws-sdk-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/jeskew/aws-sdk-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/jeskew/aws-sdk-php/contents/{+path}","compare_url":"https://api.github.com/repos/jeskew/aws-sdk-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jeskew/aws-sdk-php/merges","archive_url":"https://api.github.com/repos/jeskew/aws-sdk-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jeskew/aws-sdk-php/downloads","issues_url":"https://api.github.com/repos/jeskew/aws-sdk-php/issues{/number}","pulls_url":"https://api.github.com/repos/jeskew/aws-sdk-php/pulls{/number}","milestones_url":"https://api.github.com/repos/jeskew/aws-sdk-php/milestones{/number}","notifications_url":"https://api.github.com/repos/jeskew/aws-sdk-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jeskew/aws-sdk-php/labels{/name}","releases_url":"https://api.github.com/repos/jeskew/aws-sdk-php/releases{/id}","created_at":"2015-06-09T16:13:26Z","updated_at":"2015-06-09T16:13:29Z","pushed_at":"2015-08-07T17:04:37Z","git_url":"git://github.com/jeskew/aws-sdk-php.git","ssh_url":"git@github.com:jeskew/aws-sdk-php.git","clone_url":"https://github.com/jeskew/aws-sdk-php.git","svn_url":"https://github.com/jeskew/aws-sdk-php","homepage":"http://aws.amazon.com/sdkforphp","size":13699,"stargazers_count":0,"watchers_count":0,"language":"PHP","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":"aws:2.8","ref":"2.8","sha":"2f854073d68ee891c1e582015a423938942aa913","user":{"login":"aws","id":2232217,"avatar_url":"https://avatars.githubusercontent.com/u/2232217?v=3","gravatar_id":"","url":"https://api.github.com/users/aws","html_url":"https://github.com/aws","followers_url":"https://api.github.com/users/aws/followers","following_url":"https://api.github.com/users/aws/following{/other_user}","gists_url":"https://api.github.com/users/aws/gists{/gist_id}","starred_url":"https://api.github.com/users/aws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aws/subscriptions","organizations_url":"https://api.github.com/users/aws/orgs","repos_url":"https://api.github.com/users/aws/repos","events_url":"https://api.github.com/users/aws/events{/privacy}","received_events_url":"https://api.github.com/users/aws/received_events","type":"Organization","site_admin":false},"repo":{"id":6269013,"name":"aws-sdk-php","full_name":"aws/aws-sdk-php","owner":{"login":"aws","id":2232217,"avatar_url":"https://avatars.githubusercontent.com/u/2232217?v=3","gravatar_id":"","url":"https://api.github.com/users/aws","html_url":"https://github.com/aws","followers_url":"https://api.github.com/users/aws/followers","following_url":"https://api.github.com/users/aws/following{/other_user}","gists_url":"https://api.github.com/users/aws/gists{/gist_id}","starred_url":"https://api.github.com/users/aws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aws/subscriptions","organizations_url":"https://api.github.com/users/aws/orgs","repos_url":"https://api.github.com/users/aws/repos","events_url":"https://api.github.com/users/aws/events{/privacy}","received_events_url":"https://api.github.com/users/aws/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/aws/aws-sdk-php","description":"Official repository of the AWS SDK for PHP (@awsforphp)","fork":false,"url":"https://api.github.com/repos/aws/aws-sdk-php","forks_url":"https://api.github.com/repos/aws/aws-sdk-php/forks","keys_url":"https://api.github.com/repos/aws/aws-sdk-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aws/aws-sdk-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aws/aws-sdk-php/teams","hooks_url":"https://api.github.com/repos/aws/aws-sdk-php/hooks","issue_events_url":"https://api.github.com/repos/aws/aws-sdk-php/issues/events{/number}","events_url":"https://api.github.com/repos/aws/aws-sdk-php/events","assignees_url":"https://api.github.com/repos/aws/aws-sdk-php/assignees{/user}","branches_url":"https://api.github.com/repos/aws/aws-sdk-php/branches{/branch}","tags_url":"https://api.github.com/repos/aws/aws-sdk-php/tags","blobs_url":"https://api.github.com/repos/aws/aws-sdk-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aws/aws-sdk-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aws/aws-sdk-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/aws/aws-sdk-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aws/aws-sdk-php/statuses/{sha}","languages_url":"https://api.github.com/repos/aws/aws-sdk-php/languages","stargazers_url":"https://api.github.com/repos/aws/aws-sdk-php/stargazers","contributors_url":"https://api.github.com/repos/aws/aws-sdk-php/contributors","subscribers_url":"https://api.github.com/repos/aws/aws-sdk-php/subscribers","subscription_url":"https://api.github.com/repos/aws/aws-sdk-php/subscription","commits_url":"https://api.github.com/repos/aws/aws-sdk-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/aws/aws-sdk-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/aws/aws-sdk-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/aws/aws-sdk-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/aws/aws-sdk-php/contents/{+path}","compare_url":"https://api.github.com/repos/aws/aws-sdk-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aws/aws-sdk-php/merges","archive_url":"https://api.github.com/repos/aws/aws-sdk-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aws/aws-sdk-php/downloads","issues_url":"https://api.github.com/repos/aws/aws-sdk-php/issues{/number}","pulls_url":"https://api.github.com/repos/aws/aws-sdk-php/pulls{/number}","milestones_url":"https://api.github.com/repos/aws/aws-sdk-php/milestones{/number}","notifications_url":"https://api.github.com/repos/aws/aws-sdk-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aws/aws-sdk-php/labels{/name}","releases_url":"https://api.github.com/repos/aws/aws-sdk-php/releases{/id}","created_at":"2012-10-17T21:28:32Z","updated_at":"2015-08-07T11:46:28Z","pushed_at":"2015-08-07T17:04:38Z","git_url":"git://github.com/aws/aws-sdk-php.git","ssh_url":"git@github.com:aws/aws-sdk-php.git","clone_url":"https://github.com/aws/aws-sdk-php.git","svn_url":"https://github.com/aws/aws-sdk-php","homepage":"http://aws.amazon.com/sdkforphp","size":32203,"stargazers_count":1680,"watchers_count":1680,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":456,"mirror_url":null,"open_issues_count":17,"forks":456,"open_issues":17,"watchers":1680,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718"},"html":{"href":"https://github.com/aws/aws-sdk-php/pull/718"},"issue":{"href":"https://api.github.com/repos/aws/aws-sdk-php/issues/718"},"comments":{"href":"https://api.github.com/repos/aws/aws-sdk-php/issues/718/comments"},"review_comments":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718/comments"},"review_comment":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aws/aws-sdk-php/pulls/718/commits"},"statuses":{"href":"https://api.github.com/repos/aws/aws-sdk-php/statuses/0335272f744cf175e368a9f2d508c5049bcc4f24"}}}}