{"action":"created","comment":{"url":"https://api.github.com/repos/MyceliumGear/straight/pulls/comments/41773488","id":41773488,"diff_hunk":"@@ -128,16 +128,17 @@ def get_transaction_status(reload: false, transactions: nil)\n             [transaction(reload: reload)]\n           end.compact\n \n-        amount_paid = transactions.map { |t| t.amount }.reduce(:+) || 0\n+        uniq_transactions = transactions.group_by(&:tid).each_value.map(&:first)","path":"lib/straight/order.rb","position":5,"original_position":5,"commit_id":"d41922f7714ccdaf18a779faf6ae1f611ee90785","original_commit_id":"d41922f7714ccdaf18a779faf6ae1f611ee90785","user":{"login":"AlexanderPavlenko","id":505121,"avatar_url":"https://avatars.githubusercontent.com/u/505121?v=3","gravatar_id":"","url":"https://api.github.com/users/AlexanderPavlenko","html_url":"https://github.com/AlexanderPavlenko","followers_url":"https://api.github.com/users/AlexanderPavlenko/followers","following_url":"https://api.github.com/users/AlexanderPavlenko/following{/other_user}","gists_url":"https://api.github.com/users/AlexanderPavlenko/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexanderPavlenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexanderPavlenko/subscriptions","organizations_url":"https://api.github.com/users/AlexanderPavlenko/orgs","repos_url":"https://api.github.com/users/AlexanderPavlenko/repos","events_url":"https://api.github.com/users/AlexanderPavlenko/events{/privacy}","received_events_url":"https://api.github.com/users/AlexanderPavlenko/received_events","type":"User","site_admin":false},"body":"Yeah, but explicit version gives more control over which transactions are picked.\r\nCurrenly, it's a `&:first`, but who knows, maybe some additional checks will be required.","created_at":"2015-10-12T16:17:55Z","updated_at":"2015-10-12T16:17:55Z","html_url":"https://github.com/MyceliumGear/straight/pull/16#discussion_r41773488","pull_request_url":"https://api.github.com/repos/MyceliumGear/straight/pulls/16","_links":{"self":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/comments/41773488"},"html":{"href":"https://github.com/MyceliumGear/straight/pull/16#discussion_r41773488"},"pull_request":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/16"}}},"pull_request":{"url":"https://api.github.com/repos/MyceliumGear/straight/pulls/16","id":47395306,"html_url":"https://github.com/MyceliumGear/straight/pull/16","diff_url":"https://github.com/MyceliumGear/straight/pull/16.diff","patch_url":"https://github.com/MyceliumGear/straight/pull/16.patch","issue_url":"https://api.github.com/repos/MyceliumGear/straight/issues/16","number":16,"state":"open","locked":false,"title":"support multiple Insight servers usage","user":{"login":"AlexanderPavlenko","id":505121,"avatar_url":"https://avatars.githubusercontent.com/u/505121?v=3","gravatar_id":"","url":"https://api.github.com/users/AlexanderPavlenko","html_url":"https://github.com/AlexanderPavlenko","followers_url":"https://api.github.com/users/AlexanderPavlenko/followers","following_url":"https://api.github.com/users/AlexanderPavlenko/following{/other_user}","gists_url":"https://api.github.com/users/AlexanderPavlenko/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexanderPavlenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexanderPavlenko/subscriptions","organizations_url":"https://api.github.com/users/AlexanderPavlenko/orgs","repos_url":"https://api.github.com/users/AlexanderPavlenko/repos","events_url":"https://api.github.com/users/AlexanderPavlenko/events{/privacy}","received_events_url":"https://api.github.com/users/AlexanderPavlenko/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-10-12T08:31:05Z","updated_at":"2015-10-12T16:17:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"75fc4fb0e18cee9682b88c2133f20d5dde50a28b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/MyceliumGear/straight/pulls/16/commits","review_comments_url":"https://api.github.com/repos/MyceliumGear/straight/pulls/16/comments","review_comment_url":"https://api.github.com/repos/MyceliumGear/straight/pulls/comments{/number}","comments_url":"https://api.github.com/repos/MyceliumGear/straight/issues/16/comments","statuses_url":"https://api.github.com/repos/MyceliumGear/straight/statuses/d41922f7714ccdaf18a779faf6ae1f611ee90785","head":{"label":"MyceliumGear:multi_insight","ref":"multi_insight","sha":"d41922f7714ccdaf18a779faf6ae1f611ee90785","user":{"login":"MyceliumGear","id":12479782,"avatar_url":"https://avatars.githubusercontent.com/u/12479782?v=3","gravatar_id":"","url":"https://api.github.com/users/MyceliumGear","html_url":"https://github.com/MyceliumGear","followers_url":"https://api.github.com/users/MyceliumGear/followers","following_url":"https://api.github.com/users/MyceliumGear/following{/other_user}","gists_url":"https://api.github.com/users/MyceliumGear/gists{/gist_id}","starred_url":"https://api.github.com/users/MyceliumGear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MyceliumGear/subscriptions","organizations_url":"https://api.github.com/users/MyceliumGear/orgs","repos_url":"https://api.github.com/users/MyceliumGear/repos","events_url":"https://api.github.com/users/MyceliumGear/events{/privacy}","received_events_url":"https://api.github.com/users/MyceliumGear/received_events","type":"Organization","site_admin":false},"repo":{"id":39064763,"name":"straight","full_name":"MyceliumGear/straight","owner":{"login":"MyceliumGear","id":12479782,"avatar_url":"https://avatars.githubusercontent.com/u/12479782?v=3","gravatar_id":"","url":"https://api.github.com/users/MyceliumGear","html_url":"https://github.com/MyceliumGear","followers_url":"https://api.github.com/users/MyceliumGear/followers","following_url":"https://api.github.com/users/MyceliumGear/following{/other_user}","gists_url":"https://api.github.com/users/MyceliumGear/gists{/gist_id}","starred_url":"https://api.github.com/users/MyceliumGear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MyceliumGear/subscriptions","organizations_url":"https://api.github.com/users/MyceliumGear/orgs","repos_url":"https://api.github.com/users/MyceliumGear/repos","events_url":"https://api.github.com/users/MyceliumGear/events{/privacy}","received_events_url":"https://api.github.com/users/MyceliumGear/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MyceliumGear/straight","description":"Stateless library for tracking Blockchain transactions","fork":false,"url":"https://api.github.com/repos/MyceliumGear/straight","forks_url":"https://api.github.com/repos/MyceliumGear/straight/forks","keys_url":"https://api.github.com/repos/MyceliumGear/straight/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MyceliumGear/straight/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MyceliumGear/straight/teams","hooks_url":"https://api.github.com/repos/MyceliumGear/straight/hooks","issue_events_url":"https://api.github.com/repos/MyceliumGear/straight/issues/events{/number}","events_url":"https://api.github.com/repos/MyceliumGear/straight/events","assignees_url":"https://api.github.com/repos/MyceliumGear/straight/assignees{/user}","branches_url":"https://api.github.com/repos/MyceliumGear/straight/branches{/branch}","tags_url":"https://api.github.com/repos/MyceliumGear/straight/tags","blobs_url":"https://api.github.com/repos/MyceliumGear/straight/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MyceliumGear/straight/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MyceliumGear/straight/git/refs{/sha}","trees_url":"https://api.github.com/repos/MyceliumGear/straight/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MyceliumGear/straight/statuses/{sha}","languages_url":"https://api.github.com/repos/MyceliumGear/straight/languages","stargazers_url":"https://api.github.com/repos/MyceliumGear/straight/stargazers","contributors_url":"https://api.github.com/repos/MyceliumGear/straight/contributors","subscribers_url":"https://api.github.com/repos/MyceliumGear/straight/subscribers","subscription_url":"https://api.github.com/repos/MyceliumGear/straight/subscription","commits_url":"https://api.github.com/repos/MyceliumGear/straight/commits{/sha}","git_commits_url":"https://api.github.com/repos/MyceliumGear/straight/git/commits{/sha}","comments_url":"https://api.github.com/repos/MyceliumGear/straight/comments{/number}","issue_comment_url":"https://api.github.com/repos/MyceliumGear/straight/issues/comments{/number}","contents_url":"https://api.github.com/repos/MyceliumGear/straight/contents/{+path}","compare_url":"https://api.github.com/repos/MyceliumGear/straight/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MyceliumGear/straight/merges","archive_url":"https://api.github.com/repos/MyceliumGear/straight/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MyceliumGear/straight/downloads","issues_url":"https://api.github.com/repos/MyceliumGear/straight/issues{/number}","pulls_url":"https://api.github.com/repos/MyceliumGear/straight/pulls{/number}","milestones_url":"https://api.github.com/repos/MyceliumGear/straight/milestones{/number}","notifications_url":"https://api.github.com/repos/MyceliumGear/straight/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MyceliumGear/straight/labels{/name}","releases_url":"https://api.github.com/repos/MyceliumGear/straight/releases{/id}","created_at":"2015-07-14T09:01:56Z","updated_at":"2015-08-19T10:03:42Z","pushed_at":"2015-10-12T13:30:52Z","git_url":"git://github.com/MyceliumGear/straight.git","ssh_url":"git@github.com:MyceliumGear/straight.git","clone_url":"https://github.com/MyceliumGear/straight.git","svn_url":"https://github.com/MyceliumGear/straight","homepage":null,"size":1348,"stargazers_count":1,"watchers_count":1,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"MyceliumGear:master","ref":"master","sha":"791950aaac1613d6b1bd9c6e7ff14c9cd7076f98","user":{"login":"MyceliumGear","id":12479782,"avatar_url":"https://avatars.githubusercontent.com/u/12479782?v=3","gravatar_id":"","url":"https://api.github.com/users/MyceliumGear","html_url":"https://github.com/MyceliumGear","followers_url":"https://api.github.com/users/MyceliumGear/followers","following_url":"https://api.github.com/users/MyceliumGear/following{/other_user}","gists_url":"https://api.github.com/users/MyceliumGear/gists{/gist_id}","starred_url":"https://api.github.com/users/MyceliumGear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MyceliumGear/subscriptions","organizations_url":"https://api.github.com/users/MyceliumGear/orgs","repos_url":"https://api.github.com/users/MyceliumGear/repos","events_url":"https://api.github.com/users/MyceliumGear/events{/privacy}","received_events_url":"https://api.github.com/users/MyceliumGear/received_events","type":"Organization","site_admin":false},"repo":{"id":39064763,"name":"straight","full_name":"MyceliumGear/straight","owner":{"login":"MyceliumGear","id":12479782,"avatar_url":"https://avatars.githubusercontent.com/u/12479782?v=3","gravatar_id":"","url":"https://api.github.com/users/MyceliumGear","html_url":"https://github.com/MyceliumGear","followers_url":"https://api.github.com/users/MyceliumGear/followers","following_url":"https://api.github.com/users/MyceliumGear/following{/other_user}","gists_url":"https://api.github.com/users/MyceliumGear/gists{/gist_id}","starred_url":"https://api.github.com/users/MyceliumGear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MyceliumGear/subscriptions","organizations_url":"https://api.github.com/users/MyceliumGear/orgs","repos_url":"https://api.github.com/users/MyceliumGear/repos","events_url":"https://api.github.com/users/MyceliumGear/events{/privacy}","received_events_url":"https://api.github.com/users/MyceliumGear/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MyceliumGear/straight","description":"Stateless library for tracking Blockchain transactions","fork":false,"url":"https://api.github.com/repos/MyceliumGear/straight","forks_url":"https://api.github.com/repos/MyceliumGear/straight/forks","keys_url":"https://api.github.com/repos/MyceliumGear/straight/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MyceliumGear/straight/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MyceliumGear/straight/teams","hooks_url":"https://api.github.com/repos/MyceliumGear/straight/hooks","issue_events_url":"https://api.github.com/repos/MyceliumGear/straight/issues/events{/number}","events_url":"https://api.github.com/repos/MyceliumGear/straight/events","assignees_url":"https://api.github.com/repos/MyceliumGear/straight/assignees{/user}","branches_url":"https://api.github.com/repos/MyceliumGear/straight/branches{/branch}","tags_url":"https://api.github.com/repos/MyceliumGear/straight/tags","blobs_url":"https://api.github.com/repos/MyceliumGear/straight/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MyceliumGear/straight/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MyceliumGear/straight/git/refs{/sha}","trees_url":"https://api.github.com/repos/MyceliumGear/straight/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MyceliumGear/straight/statuses/{sha}","languages_url":"https://api.github.com/repos/MyceliumGear/straight/languages","stargazers_url":"https://api.github.com/repos/MyceliumGear/straight/stargazers","contributors_url":"https://api.github.com/repos/MyceliumGear/straight/contributors","subscribers_url":"https://api.github.com/repos/MyceliumGear/straight/subscribers","subscription_url":"https://api.github.com/repos/MyceliumGear/straight/subscription","commits_url":"https://api.github.com/repos/MyceliumGear/straight/commits{/sha}","git_commits_url":"https://api.github.com/repos/MyceliumGear/straight/git/commits{/sha}","comments_url":"https://api.github.com/repos/MyceliumGear/straight/comments{/number}","issue_comment_url":"https://api.github.com/repos/MyceliumGear/straight/issues/comments{/number}","contents_url":"https://api.github.com/repos/MyceliumGear/straight/contents/{+path}","compare_url":"https://api.github.com/repos/MyceliumGear/straight/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MyceliumGear/straight/merges","archive_url":"https://api.github.com/repos/MyceliumGear/straight/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MyceliumGear/straight/downloads","issues_url":"https://api.github.com/repos/MyceliumGear/straight/issues{/number}","pulls_url":"https://api.github.com/repos/MyceliumGear/straight/pulls{/number}","milestones_url":"https://api.github.com/repos/MyceliumGear/straight/milestones{/number}","notifications_url":"https://api.github.com/repos/MyceliumGear/straight/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MyceliumGear/straight/labels{/name}","releases_url":"https://api.github.com/repos/MyceliumGear/straight/releases{/id}","created_at":"2015-07-14T09:01:56Z","updated_at":"2015-08-19T10:03:42Z","pushed_at":"2015-10-12T13:30:52Z","git_url":"git://github.com/MyceliumGear/straight.git","ssh_url":"git@github.com:MyceliumGear/straight.git","clone_url":"https://github.com/MyceliumGear/straight.git","svn_url":"https://github.com/MyceliumGear/straight","homepage":null,"size":1348,"stargazers_count":1,"watchers_count":1,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/16"},"html":{"href":"https://github.com/MyceliumGear/straight/pull/16"},"issue":{"href":"https://api.github.com/repos/MyceliumGear/straight/issues/16"},"comments":{"href":"https://api.github.com/repos/MyceliumGear/straight/issues/16/comments"},"review_comments":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/16/comments"},"review_comment":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/MyceliumGear/straight/pulls/16/commits"},"statuses":{"href":"https://api.github.com/repos/MyceliumGear/straight/statuses/d41922f7714ccdaf18a779faf6ae1f611ee90785"}}}}