{"action":"created","comment":{"url":"https://api.github.com/repos/ripple/ripple-rest/pulls/comments/28719268","id":28719268,"diff_hunk":"@@ -19,28 +19,15 @@ function RestToTxConverter() {}\n  *  @param {ripple-lib Transaction} transaction\n  */\n RestToTxConverter.prototype.convert = function(payment, callback) {\n-  function isSendMaxRequired() {\n-    var src = payment.source_account;\n-\n+  function isSendMaxAllowed() {\n     var srcAmt = payment.source_amount;\n     var dstAmt = payment.destination_amount;\n \n     // Don't set SendMax for XRP->XRP payment\n-    if (!srcAmt || srcAmt.currency === 'XRP' && dstAmt.currency === 'XRP') {\n-      return false;\n-    }\n-\n-      // only set send max when:\n-      // - source and destination currencies are same\n-      //   and source issuer is not source account\n-      // - source amount and destination issuers are different\n-      //\n-    if (srcAmt.currency === dstAmt.currency) {\n-      if (srcAmt.issuer !== src && srcAmt.issuer !== dstAmt.issuer) {\n-        return true;\n-      }\n-    }\n-    return false;\n+    // temREDUNDANT_SEND_MAX removed in:\n+    // https://github.com/ripple/rippled/commit/\n+    //  c522ffa6db2648f1d8a987843e7feabf1a0b7de8/\n+    return srcAmt && srcAmt.currency !== 'XRP' && dstAmt.currency !== 'XRP';","path":"api/lib/rest-to-tx-converter.js","position":30,"original_position":30,"commit_id":"98c6e588fe58a408aa35f7253b398fc4d80e57e2","original_commit_id":"98c6e588fe58a408aa35f7253b398fc4d80e57e2","user":{"login":"clark800","id":1238722,"avatar_url":"https://avatars.githubusercontent.com/u/1238722?v=3","gravatar_id":"","url":"https://api.github.com/users/clark800","html_url":"https://github.com/clark800","followers_url":"https://api.github.com/users/clark800/followers","following_url":"https://api.github.com/users/clark800/following{/other_user}","gists_url":"https://api.github.com/users/clark800/gists{/gist_id}","starred_url":"https://api.github.com/users/clark800/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clark800/subscriptions","organizations_url":"https://api.github.com/users/clark800/orgs","repos_url":"https://api.github.com/users/clark800/repos","events_url":"https://api.github.com/users/clark800/events{/privacy}","received_events_url":"https://api.github.com/users/clark800/received_events","type":"User","site_admin":false},"body":"I believe your first and second comments contradict each other.","created_at":"2015-04-20T19:13:05Z","updated_at":"2015-04-20T19:13:05Z","html_url":"https://github.com/ripple/ripple-rest/pull/357#discussion_r28719268","pull_request_url":"https://api.github.com/repos/ripple/ripple-rest/pulls/357","_links":{"self":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/comments/28719268"},"html":{"href":"https://github.com/ripple/ripple-rest/pull/357#discussion_r28719268"},"pull_request":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/357"}}},"pull_request":{"url":"https://api.github.com/repos/ripple/ripple-rest/pulls/357","id":33688130,"html_url":"https://github.com/ripple/ripple-rest/pull/357","diff_url":"https://github.com/ripple/ripple-rest/pull/357.diff","patch_url":"https://github.com/ripple/ripple-rest/pull/357.patch","issue_url":"https://api.github.com/repos/ripple/ripple-rest/issues/357","number":357,"state":"open","locked":false,"title":"Update SendMax logic to match rippled 0.28 (RLJS-336)","user":{"login":"lumberj","id":1812196,"avatar_url":"https://avatars.githubusercontent.com/u/1812196?v=3","gravatar_id":"","url":"https://api.github.com/users/lumberj","html_url":"https://github.com/lumberj","followers_url":"https://api.github.com/users/lumberj/followers","following_url":"https://api.github.com/users/lumberj/following{/other_user}","gists_url":"https://api.github.com/users/lumberj/gists{/gist_id}","starred_url":"https://api.github.com/users/lumberj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lumberj/subscriptions","organizations_url":"https://api.github.com/users/lumberj/orgs","repos_url":"https://api.github.com/users/lumberj/repos","events_url":"https://api.github.com/users/lumberj/events{/privacy}","received_events_url":"https://api.github.com/users/lumberj/received_events","type":"User","site_admin":false},"body":"- rippled 0.28 removes temredundant_send_max, in\r\nhttps://github.com/ripple/rippled/commit/c522ffa6db2648f1d8a987843e7feabf1a0b7de8/","created_at":"2015-04-20T17:37:08Z","updated_at":"2015-04-20T19:13:05Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ef894956cd0a2838e451ea5cd6091994d290ca2b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ripple/ripple-rest/pulls/357/commits","review_comments_url":"https://api.github.com/repos/ripple/ripple-rest/pulls/357/comments","review_comment_url":"https://api.github.com/repos/ripple/ripple-rest/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ripple/ripple-rest/issues/357/comments","statuses_url":"https://api.github.com/repos/ripple/ripple-rest/statuses/98c6e588fe58a408aa35f7253b398fc4d80e57e2","head":{"label":"lumberj:task/sendmax-update","ref":"task/sendmax-update","sha":"98c6e588fe58a408aa35f7253b398fc4d80e57e2","user":{"login":"lumberj","id":1812196,"avatar_url":"https://avatars.githubusercontent.com/u/1812196?v=3","gravatar_id":"","url":"https://api.github.com/users/lumberj","html_url":"https://github.com/lumberj","followers_url":"https://api.github.com/users/lumberj/followers","following_url":"https://api.github.com/users/lumberj/following{/other_user}","gists_url":"https://api.github.com/users/lumberj/gists{/gist_id}","starred_url":"https://api.github.com/users/lumberj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lumberj/subscriptions","organizations_url":"https://api.github.com/users/lumberj/orgs","repos_url":"https://api.github.com/users/lumberj/repos","events_url":"https://api.github.com/users/lumberj/events{/privacy}","received_events_url":"https://api.github.com/users/lumberj/received_events","type":"User","site_admin":false},"repo":{"id":27409911,"name":"ripple-rest","full_name":"lumberj/ripple-rest","owner":{"login":"lumberj","id":1812196,"avatar_url":"https://avatars.githubusercontent.com/u/1812196?v=3","gravatar_id":"","url":"https://api.github.com/users/lumberj","html_url":"https://github.com/lumberj","followers_url":"https://api.github.com/users/lumberj/followers","following_url":"https://api.github.com/users/lumberj/following{/other_user}","gists_url":"https://api.github.com/users/lumberj/gists{/gist_id}","starred_url":"https://api.github.com/users/lumberj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lumberj/subscriptions","organizations_url":"https://api.github.com/users/lumberj/orgs","repos_url":"https://api.github.com/users/lumberj/repos","events_url":"https://api.github.com/users/lumberj/events{/privacy}","received_events_url":"https://api.github.com/users/lumberj/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lumberj/ripple-rest","description":"A RESTful API for submitting payments and monitoring accounts on the Ripple Network","fork":true,"url":"https://api.github.com/repos/lumberj/ripple-rest","forks_url":"https://api.github.com/repos/lumberj/ripple-rest/forks","keys_url":"https://api.github.com/repos/lumberj/ripple-rest/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lumberj/ripple-rest/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lumberj/ripple-rest/teams","hooks_url":"https://api.github.com/repos/lumberj/ripple-rest/hooks","issue_events_url":"https://api.github.com/repos/lumberj/ripple-rest/issues/events{/number}","events_url":"https://api.github.com/repos/lumberj/ripple-rest/events","assignees_url":"https://api.github.com/repos/lumberj/ripple-rest/assignees{/user}","branches_url":"https://api.github.com/repos/lumberj/ripple-rest/branches{/branch}","tags_url":"https://api.github.com/repos/lumberj/ripple-rest/tags","blobs_url":"https://api.github.com/repos/lumberj/ripple-rest/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lumberj/ripple-rest/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lumberj/ripple-rest/git/refs{/sha}","trees_url":"https://api.github.com/repos/lumberj/ripple-rest/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lumberj/ripple-rest/statuses/{sha}","languages_url":"https://api.github.com/repos/lumberj/ripple-rest/languages","stargazers_url":"https://api.github.com/repos/lumberj/ripple-rest/stargazers","contributors_url":"https://api.github.com/repos/lumberj/ripple-rest/contributors","subscribers_url":"https://api.github.com/repos/lumberj/ripple-rest/subscribers","subscription_url":"https://api.github.com/repos/lumberj/ripple-rest/subscription","commits_url":"https://api.github.com/repos/lumberj/ripple-rest/commits{/sha}","git_commits_url":"https://api.github.com/repos/lumberj/ripple-rest/git/commits{/sha}","comments_url":"https://api.github.com/repos/lumberj/ripple-rest/comments{/number}","issue_comment_url":"https://api.github.com/repos/lumberj/ripple-rest/issues/comments{/number}","contents_url":"https://api.github.com/repos/lumberj/ripple-rest/contents/{+path}","compare_url":"https://api.github.com/repos/lumberj/ripple-rest/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lumberj/ripple-rest/merges","archive_url":"https://api.github.com/repos/lumberj/ripple-rest/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lumberj/ripple-rest/downloads","issues_url":"https://api.github.com/repos/lumberj/ripple-rest/issues{/number}","pulls_url":"https://api.github.com/repos/lumberj/ripple-rest/pulls{/number}","milestones_url":"https://api.github.com/repos/lumberj/ripple-rest/milestones{/number}","notifications_url":"https://api.github.com/repos/lumberj/ripple-rest/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lumberj/ripple-rest/labels{/name}","releases_url":"https://api.github.com/repos/lumberj/ripple-rest/releases{/id}","created_at":"2014-12-02T01:53:04Z","updated_at":"2015-03-03T17:31:53Z","pushed_at":"2015-04-20T19:01:13Z","git_url":"git://github.com/lumberj/ripple-rest.git","ssh_url":"git@github.com:lumberj/ripple-rest.git","clone_url":"https://github.com/lumberj/ripple-rest.git","svn_url":"https://github.com/lumberj/ripple-rest","homepage":"","size":3348,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"ripple:release","ref":"release","sha":"0863b5a3af007f96bdea7e9ad386c50d728e7e03","user":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"repo":{"id":16561603,"name":"ripple-rest","full_name":"ripple/ripple-rest","owner":{"login":"ripple","id":3165523,"avatar_url":"https://avatars.githubusercontent.com/u/3165523?v=3","gravatar_id":"","url":"https://api.github.com/users/ripple","html_url":"https://github.com/ripple","followers_url":"https://api.github.com/users/ripple/followers","following_url":"https://api.github.com/users/ripple/following{/other_user}","gists_url":"https://api.github.com/users/ripple/gists{/gist_id}","starred_url":"https://api.github.com/users/ripple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ripple/subscriptions","organizations_url":"https://api.github.com/users/ripple/orgs","repos_url":"https://api.github.com/users/ripple/repos","events_url":"https://api.github.com/users/ripple/events{/privacy}","received_events_url":"https://api.github.com/users/ripple/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ripple/ripple-rest","description":"A RESTful API for submitting payments and monitoring accounts on the Ripple Network","fork":false,"url":"https://api.github.com/repos/ripple/ripple-rest","forks_url":"https://api.github.com/repos/ripple/ripple-rest/forks","keys_url":"https://api.github.com/repos/ripple/ripple-rest/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ripple/ripple-rest/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ripple/ripple-rest/teams","hooks_url":"https://api.github.com/repos/ripple/ripple-rest/hooks","issue_events_url":"https://api.github.com/repos/ripple/ripple-rest/issues/events{/number}","events_url":"https://api.github.com/repos/ripple/ripple-rest/events","assignees_url":"https://api.github.com/repos/ripple/ripple-rest/assignees{/user}","branches_url":"https://api.github.com/repos/ripple/ripple-rest/branches{/branch}","tags_url":"https://api.github.com/repos/ripple/ripple-rest/tags","blobs_url":"https://api.github.com/repos/ripple/ripple-rest/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ripple/ripple-rest/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ripple/ripple-rest/git/refs{/sha}","trees_url":"https://api.github.com/repos/ripple/ripple-rest/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ripple/ripple-rest/statuses/{sha}","languages_url":"https://api.github.com/repos/ripple/ripple-rest/languages","stargazers_url":"https://api.github.com/repos/ripple/ripple-rest/stargazers","contributors_url":"https://api.github.com/repos/ripple/ripple-rest/contributors","subscribers_url":"https://api.github.com/repos/ripple/ripple-rest/subscribers","subscription_url":"https://api.github.com/repos/ripple/ripple-rest/subscription","commits_url":"https://api.github.com/repos/ripple/ripple-rest/commits{/sha}","git_commits_url":"https://api.github.com/repos/ripple/ripple-rest/git/commits{/sha}","comments_url":"https://api.github.com/repos/ripple/ripple-rest/comments{/number}","issue_comment_url":"https://api.github.com/repos/ripple/ripple-rest/issues/comments{/number}","contents_url":"https://api.github.com/repos/ripple/ripple-rest/contents/{+path}","compare_url":"https://api.github.com/repos/ripple/ripple-rest/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ripple/ripple-rest/merges","archive_url":"https://api.github.com/repos/ripple/ripple-rest/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ripple/ripple-rest/downloads","issues_url":"https://api.github.com/repos/ripple/ripple-rest/issues{/number}","pulls_url":"https://api.github.com/repos/ripple/ripple-rest/pulls{/number}","milestones_url":"https://api.github.com/repos/ripple/ripple-rest/milestones{/number}","notifications_url":"https://api.github.com/repos/ripple/ripple-rest/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ripple/ripple-rest/labels{/name}","releases_url":"https://api.github.com/repos/ripple/ripple-rest/releases{/id}","created_at":"2014-02-05T22:52:44Z","updated_at":"2015-04-18T05:06:37Z","pushed_at":"2015-04-20T19:01:13Z","git_url":"git://github.com/ripple/ripple-rest.git","ssh_url":"git@github.com:ripple/ripple-rest.git","clone_url":"https://github.com/ripple/ripple-rest.git","svn_url":"https://github.com/ripple/ripple-rest","homepage":"","size":7451,"stargazers_count":65,"watchers_count":65,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":70,"mirror_url":null,"open_issues_count":9,"forks":70,"open_issues":9,"watchers":65,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/357"},"html":{"href":"https://github.com/ripple/ripple-rest/pull/357"},"issue":{"href":"https://api.github.com/repos/ripple/ripple-rest/issues/357"},"comments":{"href":"https://api.github.com/repos/ripple/ripple-rest/issues/357/comments"},"review_comments":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/357/comments"},"review_comment":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ripple/ripple-rest/pulls/357/commits"},"statuses":{"href":"https://api.github.com/repos/ripple/ripple-rest/statuses/98c6e588fe58a408aa35f7253b398fc4d80e57e2"}}}}