{"action":"created","comment":{"url":"https://api.github.com/repos/decred/politeiagui/pulls/comments/232500447","pull_request_review_id":173710425,"id":232500447,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMjUwMDQ0Nw==","diff_hunk":"@@ -333,35 +340,58 @@ class GeneralTab extends React.Component {\n           </div>\n         ) : null}\n         <FieldSeparator />\n-        {!user.newuserverificationtoken ? (\n-          <Field label=\"Verified email\">Yes</Field>\n-        ) : (\n+        <Field label=\"Past Public Keys\" style={{ float: \"left\" }}>\n+          {showPastUserIdentities ? (\n+            <span>\n+              <span style={{ fontWeight: \"bold\" }}>Expanded</span>\n+              <a className=\"linkish\" style={{ paddingLeft: \"1em\" }}onClick={() => this.setState({ showPastUserIdentities: false })}>(hide)</a>\n+            </span> ) : (\n+            <a className=\"linkish\" onClick={() => this.setState({ showPastUserIdentities: true })}>Expand</a>\n+          )}\n+        </Field>\n+        {showPastUserIdentities ?\n+          <ul>{user.identities.map((identity, i) => (\n+            <ul key={i} style={{ lineHeight: \"2em\" }}>\n+              <li style={{ float: \"left\", fontWeight: \"bold\", marginRight: \".75em\", lineHeight: \"1.5em\" }}>{i + 1})</li>\n+              <li className=\"monospace\">{identity.pubkey}</li>\n+            </ul>\n+          ))}\n+          </ul>\n+          : null }\n+        <FieldSeparator />\n+        {isAdminOrTheUser ?\n           <div>\n-            <Field label=\"Verified email\">No</Field>\n-            <TokenFields\n-              tokenLabel=\"Registration token\"\n-              token={\" \" + user.newuserverificationtoken + \" \"}\n-              expiry={user.newuserverificationexpiry}\n-              userId={user.id}\n-              action={EDIT_USER_EXPIRE_NEW_USER_VERIFICATION}\n-              isRequesting={isApiRequestingMarkNewUserAsExpired}\n-              onEditUser={onEditUser} />\n-          </div>\n-        )}\n+            {!user.newuserverificationtoken ? (\n+              <Field label=\"Verified email\">Yes</Field>\n+            ) : (\n+              <div>\n+                <Field label=\"Verified email\">No</Field>\n+                <TokenFields\n+                  tokenLabel=\"Registration token\"\n+                  token={\" \" + user.newuserverificationtoken + \" \"}\n+                  expiry={user.newuserverificationexpiry}\n+                  userId={user.id}\n+                  action={EDIT_USER_EXPIRE_NEW_USER_VERIFICATION}\n+                  isRequesting={isApiRequestingMarkNewUserAsExpired}\n+                  onEditUser={onEditUser} />\n+              </div>\n+            )}\n+          </div> : null }\n         {(loggedInAsUserId === user.id) ?\n           <Field label=\"Password\"><a className=\"linkish\" onClick={() => openModal(CHANGE_PASSWORD_MODAL)}>Change Password</a></Field> : null}\n-        <FieldSeparator />\n-        <Field label=\"Has paid\">\n-          {user.newuserpaywalltx ? \"Yes\" : ([\n-            <span>No</span>,\n-            isAdmin && <ButtonWithLoadingIcon\n-              className=\"c-btn c-btn-primary button-small\"\n-              text=\"Mark as paid\"\n-              disabled={isApiRequestingMarkAsPaid}\n-              isLoading={isApiRequestingMarkAsPaid}\n-              onClick={() => onEditUser(user.id, EDIT_USER_CLEAR_USER_PAYWALL)} />\n-          ])}\n-        </Field>\n+        { isAdminOrTheUser ? <FieldSeparator /> : null }","path":"src/components/UserDetail/GeneralTab.js","position":131,"original_position":131,"commit_id":"81d5f37423bce0b0c51affb043ed7f131735252f","original_commit_id":"81d5f37423bce0b0c51affb043ed7f131735252f","user":{"login":"brunobraga95","id":14654063,"node_id":"MDQ6VXNlcjE0NjU0MDYz","avatar_url":"https://avatars2.githubusercontent.com/u/14654063?v=4","gravatar_id":"","url":"https://api.github.com/users/brunobraga95","html_url":"https://github.com/brunobraga95","followers_url":"https://api.github.com/users/brunobraga95/followers","following_url":"https://api.github.com/users/brunobraga95/following{/other_user}","gists_url":"https://api.github.com/users/brunobraga95/gists{/gist_id}","starred_url":"https://api.github.com/users/brunobraga95/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brunobraga95/subscriptions","organizations_url":"https://api.github.com/users/brunobraga95/orgs","repos_url":"https://api.github.com/users/brunobraga95/repos","events_url":"https://api.github.com/users/brunobraga95/events{/privacy}","received_events_url":"https://api.github.com/users/brunobraga95/received_events","type":"User","site_admin":false},"body":"if you take a look here, you are doing the following:\r\n\r\n```\r\nif(X) {\r\n  doFoo();\r\n}\r\n\r\nif(X) {\r\n  dobar();\r\n}\r\n```\r\n\r\nwhich is the same as \r\n```\r\nif(X) {\r\n  doFoo();\r\n  doBar();\r\n}\r\n```\r\n\r\nyou can just \r\n```\r\n{isAdmingOrTheUser ? \r\n  <React.Fragment>\r\n    <FieldSeparator />\r\n    <Field label = \"has paid\">\r\n       .....\r\n   </Field>\r\n  </React.Fragment>\r\n :null\r\n}\r\n```","created_at":"2018-11-11T19:09:33Z","updated_at":"2018-11-11T19:09:33Z","html_url":"https://github.com/decred/politeiagui/pull/873#discussion_r232500447","pull_request_url":"https://api.github.com/repos/decred/politeiagui/pulls/873","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/comments/232500447"},"html":{"href":"https://github.com/decred/politeiagui/pull/873#discussion_r232500447"},"pull_request":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/873"}}},"pull_request":{"url":"https://api.github.com/repos/decred/politeiagui/pulls/873","id":229550079,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI5NTUwMDc5","html_url":"https://github.com/decred/politeiagui/pull/873","diff_url":"https://github.com/decred/politeiagui/pull/873.diff","patch_url":"https://github.com/decred/politeiagui/pull/873.patch","issue_url":"https://api.github.com/repos/decred/politeiagui/issues/873","number":873,"state":"open","locked":false,"title":"Add General Tab Functionality for all Users on /user/id Page","user":{"login":"camus-code","id":42082827,"node_id":"MDQ6VXNlcjQyMDgyODI3","avatar_url":"https://avatars3.githubusercontent.com/u/42082827?v=4","gravatar_id":"","url":"https://api.github.com/users/camus-code","html_url":"https://github.com/camus-code","followers_url":"https://api.github.com/users/camus-code/followers","following_url":"https://api.github.com/users/camus-code/following{/other_user}","gists_url":"https://api.github.com/users/camus-code/gists{/gist_id}","starred_url":"https://api.github.com/users/camus-code/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/camus-code/subscriptions","organizations_url":"https://api.github.com/users/camus-code/orgs","repos_url":"https://api.github.com/users/camus-code/repos","events_url":"https://api.github.com/users/camus-code/events{/privacy}","received_events_url":"https://api.github.com/users/camus-code/received_events","type":"User","site_admin":false},"body":"Resolves #871 ","created_at":"2018-11-09T00:11:42Z","updated_at":"2018-11-11T19:09:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9af60719d04a73b43da897eb54749c173d22d540","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/decred/politeiagui/pulls/873/commits","review_comments_url":"https://api.github.com/repos/decred/politeiagui/pulls/873/comments","review_comment_url":"https://api.github.com/repos/decred/politeiagui/pulls/comments{/number}","comments_url":"https://api.github.com/repos/decred/politeiagui/issues/873/comments","statuses_url":"https://api.github.com/repos/decred/politeiagui/statuses/81d5f37423bce0b0c51affb043ed7f131735252f","head":{"label":"camus-code:addGeneralTabForAllUsers","ref":"addGeneralTabForAllUsers","sha":"81d5f37423bce0b0c51affb043ed7f131735252f","user":{"login":"camus-code","id":42082827,"node_id":"MDQ6VXNlcjQyMDgyODI3","avatar_url":"https://avatars3.githubusercontent.com/u/42082827?v=4","gravatar_id":"","url":"https://api.github.com/users/camus-code","html_url":"https://github.com/camus-code","followers_url":"https://api.github.com/users/camus-code/followers","following_url":"https://api.github.com/users/camus-code/following{/other_user}","gists_url":"https://api.github.com/users/camus-code/gists{/gist_id}","starred_url":"https://api.github.com/users/camus-code/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/camus-code/subscriptions","organizations_url":"https://api.github.com/users/camus-code/orgs","repos_url":"https://api.github.com/users/camus-code/repos","events_url":"https://api.github.com/users/camus-code/events{/privacy}","received_events_url":"https://api.github.com/users/camus-code/received_events","type":"User","site_admin":false},"repo":{"id":147564275,"node_id":"MDEwOlJlcG9zaXRvcnkxNDc1NjQyNzU=","name":"politeiagui","full_name":"camus-code/politeiagui","private":false,"owner":{"login":"camus-code","id":42082827,"node_id":"MDQ6VXNlcjQyMDgyODI3","avatar_url":"https://avatars3.githubusercontent.com/u/42082827?v=4","gravatar_id":"","url":"https://api.github.com/users/camus-code","html_url":"https://github.com/camus-code","followers_url":"https://api.github.com/users/camus-code/followers","following_url":"https://api.github.com/users/camus-code/following{/other_user}","gists_url":"https://api.github.com/users/camus-code/gists{/gist_id}","starred_url":"https://api.github.com/users/camus-code/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/camus-code/subscriptions","organizations_url":"https://api.github.com/users/camus-code/orgs","repos_url":"https://api.github.com/users/camus-code/repos","events_url":"https://api.github.com/users/camus-code/events{/privacy}","received_events_url":"https://api.github.com/users/camus-code/received_events","type":"User","site_admin":false},"html_url":"https://github.com/camus-code/politeiagui","description":null,"fork":true,"url":"https://api.github.com/repos/camus-code/politeiagui","forks_url":"https://api.github.com/repos/camus-code/politeiagui/forks","keys_url":"https://api.github.com/repos/camus-code/politeiagui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/camus-code/politeiagui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/camus-code/politeiagui/teams","hooks_url":"https://api.github.com/repos/camus-code/politeiagui/hooks","issue_events_url":"https://api.github.com/repos/camus-code/politeiagui/issues/events{/number}","events_url":"https://api.github.com/repos/camus-code/politeiagui/events","assignees_url":"https://api.github.com/repos/camus-code/politeiagui/assignees{/user}","branches_url":"https://api.github.com/repos/camus-code/politeiagui/branches{/branch}","tags_url":"https://api.github.com/repos/camus-code/politeiagui/tags","blobs_url":"https://api.github.com/repos/camus-code/politeiagui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/camus-code/politeiagui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/camus-code/politeiagui/git/refs{/sha}","trees_url":"https://api.github.com/repos/camus-code/politeiagui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/camus-code/politeiagui/statuses/{sha}","languages_url":"https://api.github.com/repos/camus-code/politeiagui/languages","stargazers_url":"https://api.github.com/repos/camus-code/politeiagui/stargazers","contributors_url":"https://api.github.com/repos/camus-code/politeiagui/contributors","subscribers_url":"https://api.github.com/repos/camus-code/politeiagui/subscribers","subscription_url":"https://api.github.com/repos/camus-code/politeiagui/subscription","commits_url":"https://api.github.com/repos/camus-code/politeiagui/commits{/sha}","git_commits_url":"https://api.github.com/repos/camus-code/politeiagui/git/commits{/sha}","comments_url":"https://api.github.com/repos/camus-code/politeiagui/comments{/number}","issue_comment_url":"https://api.github.com/repos/camus-code/politeiagui/issues/comments{/number}","contents_url":"https://api.github.com/repos/camus-code/politeiagui/contents/{+path}","compare_url":"https://api.github.com/repos/camus-code/politeiagui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/camus-code/politeiagui/merges","archive_url":"https://api.github.com/repos/camus-code/politeiagui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/camus-code/politeiagui/downloads","issues_url":"https://api.github.com/repos/camus-code/politeiagui/issues{/number}","pulls_url":"https://api.github.com/repos/camus-code/politeiagui/pulls{/number}","milestones_url":"https://api.github.com/repos/camus-code/politeiagui/milestones{/number}","notifications_url":"https://api.github.com/repos/camus-code/politeiagui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/camus-code/politeiagui/labels{/name}","releases_url":"https://api.github.com/repos/camus-code/politeiagui/releases{/id}","deployments_url":"https://api.github.com/repos/camus-code/politeiagui/deployments","created_at":"2018-09-05T18:46:29Z","updated_at":"2018-09-05T18:46:31Z","pushed_at":"2018-11-09T16:55:43Z","git_url":"git://github.com/camus-code/politeiagui.git","ssh_url":"git@github.com:camus-code/politeiagui.git","clone_url":"https://github.com/camus-code/politeiagui.git","svn_url":"https://github.com/camus-code/politeiagui","homepage":null,"size":2624,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"isc","name":"ISC License","spdx_id":"ISC","url":"https://api.github.com/licenses/isc","node_id":"MDc6TGljZW5zZTEw"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"decred:master","ref":"master","sha":"9686b84118eaaa245e4e8df56210ee18c62b1e44","user":{"login":"decred","id":16297194,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE2Mjk3MTk0","avatar_url":"https://avatars3.githubusercontent.com/u/16297194?v=4","gravatar_id":"","url":"https://api.github.com/users/decred","html_url":"https://github.com/decred","followers_url":"https://api.github.com/users/decred/followers","following_url":"https://api.github.com/users/decred/following{/other_user}","gists_url":"https://api.github.com/users/decred/gists{/gist_id}","starred_url":"https://api.github.com/users/decred/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/decred/subscriptions","organizations_url":"https://api.github.com/users/decred/orgs","repos_url":"https://api.github.com/users/decred/repos","events_url":"https://api.github.com/users/decred/events{/privacy}","received_events_url":"https://api.github.com/users/decred/received_events","type":"Organization","site_admin":false},"repo":{"id":103684518,"node_id":"MDEwOlJlcG9zaXRvcnkxMDM2ODQ1MTg=","name":"politeiagui","full_name":"decred/politeiagui","private":false,"owner":{"login":"decred","id":16297194,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE2Mjk3MTk0","avatar_url":"https://avatars3.githubusercontent.com/u/16297194?v=4","gravatar_id":"","url":"https://api.github.com/users/decred","html_url":"https://github.com/decred","followers_url":"https://api.github.com/users/decred/followers","following_url":"https://api.github.com/users/decred/following{/other_user}","gists_url":"https://api.github.com/users/decred/gists{/gist_id}","starred_url":"https://api.github.com/users/decred/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/decred/subscriptions","organizations_url":"https://api.github.com/users/decred/orgs","repos_url":"https://api.github.com/users/decred/repos","events_url":"https://api.github.com/users/decred/events{/privacy}","received_events_url":"https://api.github.com/users/decred/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/decred/politeiagui","description":null,"fork":false,"url":"https://api.github.com/repos/decred/politeiagui","forks_url":"https://api.github.com/repos/decred/politeiagui/forks","keys_url":"https://api.github.com/repos/decred/politeiagui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/decred/politeiagui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/decred/politeiagui/teams","hooks_url":"https://api.github.com/repos/decred/politeiagui/hooks","issue_events_url":"https://api.github.com/repos/decred/politeiagui/issues/events{/number}","events_url":"https://api.github.com/repos/decred/politeiagui/events","assignees_url":"https://api.github.com/repos/decred/politeiagui/assignees{/user}","branches_url":"https://api.github.com/repos/decred/politeiagui/branches{/branch}","tags_url":"https://api.github.com/repos/decred/politeiagui/tags","blobs_url":"https://api.github.com/repos/decred/politeiagui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/decred/politeiagui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/decred/politeiagui/git/refs{/sha}","trees_url":"https://api.github.com/repos/decred/politeiagui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/decred/politeiagui/statuses/{sha}","languages_url":"https://api.github.com/repos/decred/politeiagui/languages","stargazers_url":"https://api.github.com/repos/decred/politeiagui/stargazers","contributors_url":"https://api.github.com/repos/decred/politeiagui/contributors","subscribers_url":"https://api.github.com/repos/decred/politeiagui/subscribers","subscription_url":"https://api.github.com/repos/decred/politeiagui/subscription","commits_url":"https://api.github.com/repos/decred/politeiagui/commits{/sha}","git_commits_url":"https://api.github.com/repos/decred/politeiagui/git/commits{/sha}","comments_url":"https://api.github.com/repos/decred/politeiagui/comments{/number}","issue_comment_url":"https://api.github.com/repos/decred/politeiagui/issues/comments{/number}","contents_url":"https://api.github.com/repos/decred/politeiagui/contents/{+path}","compare_url":"https://api.github.com/repos/decred/politeiagui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/decred/politeiagui/merges","archive_url":"https://api.github.com/repos/decred/politeiagui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/decred/politeiagui/downloads","issues_url":"https://api.github.com/repos/decred/politeiagui/issues{/number}","pulls_url":"https://api.github.com/repos/decred/politeiagui/pulls{/number}","milestones_url":"https://api.github.com/repos/decred/politeiagui/milestones{/number}","notifications_url":"https://api.github.com/repos/decred/politeiagui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/decred/politeiagui/labels{/name}","releases_url":"https://api.github.com/repos/decred/politeiagui/releases{/id}","deployments_url":"https://api.github.com/repos/decred/politeiagui/deployments","created_at":"2017-09-15T17:37:44Z","updated_at":"2018-11-09T10:05:32Z","pushed_at":"2018-11-09T16:55:44Z","git_url":"git://github.com/decred/politeiagui.git","ssh_url":"git@github.com:decred/politeiagui.git","clone_url":"https://github.com/decred/politeiagui.git","svn_url":"https://github.com/decred/politeiagui","homepage":null,"size":2610,"stargazers_count":30,"watchers_count":30,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":31,"mirror_url":null,"archived":false,"open_issues_count":55,"license":{"key":"isc","name":"ISC License","spdx_id":"ISC","url":"https://api.github.com/licenses/isc","node_id":"MDc6TGljZW5zZTEw"},"forks":31,"open_issues":55,"watchers":30,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/873"},"html":{"href":"https://github.com/decred/politeiagui/pull/873"},"issue":{"href":"https://api.github.com/repos/decred/politeiagui/issues/873"},"comments":{"href":"https://api.github.com/repos/decred/politeiagui/issues/873/comments"},"review_comments":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/873/comments"},"review_comment":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/decred/politeiagui/pulls/873/commits"},"statuses":{"href":"https://api.github.com/repos/decred/politeiagui/statuses/81d5f37423bce0b0c51affb043ed7f131735252f"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"brunobraga95"}}