{"action":"created","comment":{"url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/comments/27219187","id":27219187,"diff_hunk":"@@ -457,4 +457,25 @@ public function has_trialed() {\n \n \t}\n \n-}\n\\ No newline at end of file\n+\t/**\n+\t * Gets the URL to switch to the user\n+\t * if the User Switching plugin is active\n+\t *\n+\t * @access public\n+\t * @since 2.1\n+\t*/\n+\tpublic function get_switch_to_url() {\n+\n+\t\tif( !class_exists( 'user_switching' ) ) return false;\n+\n+\t\t$link = user_switching::maybe_switch_url( $this );\n+\t\tif ( $link ) {\n+\t\t\t$link = add_query_arg( 'redirect_to', urlencode( home_url() ), $link );\n+\t\t\treturn $link;\n+\t\t}\n+\t\telse {","path":"includes/class-rcp-member.php","position":22,"original_position":22,"commit_id":"ddc0cccd9f11f469a6939198dadb47397fabd07f","original_commit_id":"ddc0cccd9f11f469a6939198dadb47397fabd07f","user":{"login":"pippinsplugins","id":1034109,"avatar_url":"https://avatars.githubusercontent.com/u/1034109?v=3","gravatar_id":"","url":"https://api.github.com/users/pippinsplugins","html_url":"https://github.com/pippinsplugins","followers_url":"https://api.github.com/users/pippinsplugins/followers","following_url":"https://api.github.com/users/pippinsplugins/following{/other_user}","gists_url":"https://api.github.com/users/pippinsplugins/gists{/gist_id}","starred_url":"https://api.github.com/users/pippinsplugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pippinsplugins/subscriptions","organizations_url":"https://api.github.com/users/pippinsplugins/orgs","repos_url":"https://api.github.com/users/pippinsplugins/repos","events_url":"https://api.github.com/users/pippinsplugins/events{/privacy}","received_events_url":"https://api.github.com/users/pippinsplugins/received_events","type":"User","site_admin":false},"body":"Could you put `} else {` on one line?","created_at":"2015-03-26T14:50:39Z","updated_at":"2015-03-26T14:50:39Z","html_url":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138#discussion_r27219187","pull_request_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138","_links":{"self":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/comments/27219187"},"html":{"href":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138#discussion_r27219187"},"pull_request":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138"}}},"pull_request":{"url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138","id":31987275,"html_url":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138","diff_url":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138.diff","patch_url":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138.patch","issue_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/138","number":138,"state":"open","locked":false,"title":"Add user switching links if possible","user":{"login":"tnorthcutt","id":796639,"avatar_url":"https://avatars.githubusercontent.com/u/796639?v=3","gravatar_id":"","url":"https://api.github.com/users/tnorthcutt","html_url":"https://github.com/tnorthcutt","followers_url":"https://api.github.com/users/tnorthcutt/followers","following_url":"https://api.github.com/users/tnorthcutt/following{/other_user}","gists_url":"https://api.github.com/users/tnorthcutt/gists{/gist_id}","starred_url":"https://api.github.com/users/tnorthcutt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tnorthcutt/subscriptions","organizations_url":"https://api.github.com/users/tnorthcutt/orgs","repos_url":"https://api.github.com/users/tnorthcutt/repos","events_url":"https://api.github.com/users/tnorthcutt/events{/privacy}","received_events_url":"https://api.github.com/users/tnorthcutt/received_events","type":"User","site_admin":false},"body":"If the [user switching](https://wordpress.org/plugins/user-switching/) plugin is active, then user switching links will be displayed on the main members page and on each individual edit member page.\r\n\r\nFixes #129 ","created_at":"2015-03-26T03:44:03Z","updated_at":"2015-03-26T14:50:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4c605d910d77820692f878e027a0265c1d3180cc","assignee":{"login":"tnorthcutt","id":796639,"avatar_url":"https://avatars.githubusercontent.com/u/796639?v=3","gravatar_id":"","url":"https://api.github.com/users/tnorthcutt","html_url":"https://github.com/tnorthcutt","followers_url":"https://api.github.com/users/tnorthcutt/followers","following_url":"https://api.github.com/users/tnorthcutt/following{/other_user}","gists_url":"https://api.github.com/users/tnorthcutt/gists{/gist_id}","starred_url":"https://api.github.com/users/tnorthcutt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tnorthcutt/subscriptions","organizations_url":"https://api.github.com/users/tnorthcutt/orgs","repos_url":"https://api.github.com/users/tnorthcutt/repos","events_url":"https://api.github.com/users/tnorthcutt/events{/privacy}","received_events_url":"https://api.github.com/users/tnorthcutt/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/milestones/9","html_url":"https://github.com/pippinsplugins/Restrict-Content-Pro/milestones/2.1","labels_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/milestones/9/labels","id":567722,"number":9,"title":"2.1","description":null,"creator":{"login":"pippinsplugins","id":1034109,"avatar_url":"https://avatars.githubusercontent.com/u/1034109?v=3","gravatar_id":"","url":"https://api.github.com/users/pippinsplugins","html_url":"https://github.com/pippinsplugins","followers_url":"https://api.github.com/users/pippinsplugins/followers","following_url":"https://api.github.com/users/pippinsplugins/following{/other_user}","gists_url":"https://api.github.com/users/pippinsplugins/gists{/gist_id}","starred_url":"https://api.github.com/users/pippinsplugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pippinsplugins/subscriptions","organizations_url":"https://api.github.com/users/pippinsplugins/orgs","repos_url":"https://api.github.com/users/pippinsplugins/repos","events_url":"https://api.github.com/users/pippinsplugins/events{/privacy}","received_events_url":"https://api.github.com/users/pippinsplugins/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":12,"state":"open","created_at":"2014-02-12T20:27:04Z","updated_at":"2015-03-26T03:46:52Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138/commits","review_comments_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138/comments","review_comment_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/138/comments","statuses_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/statuses/ddc0cccd9f11f469a6939198dadb47397fabd07f","head":{"label":"tnorthcutt:user-switching","ref":"user-switching","sha":"ddc0cccd9f11f469a6939198dadb47397fabd07f","user":{"login":"tnorthcutt","id":796639,"avatar_url":"https://avatars.githubusercontent.com/u/796639?v=3","gravatar_id":"","url":"https://api.github.com/users/tnorthcutt","html_url":"https://github.com/tnorthcutt","followers_url":"https://api.github.com/users/tnorthcutt/followers","following_url":"https://api.github.com/users/tnorthcutt/following{/other_user}","gists_url":"https://api.github.com/users/tnorthcutt/gists{/gist_id}","starred_url":"https://api.github.com/users/tnorthcutt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tnorthcutt/subscriptions","organizations_url":"https://api.github.com/users/tnorthcutt/orgs","repos_url":"https://api.github.com/users/tnorthcutt/repos","events_url":"https://api.github.com/users/tnorthcutt/events{/privacy}","received_events_url":"https://api.github.com/users/tnorthcutt/received_events","type":"User","site_admin":false},"repo":{"id":28007100,"name":"Restrict-Content-Pro","full_name":"tnorthcutt/Restrict-Content-Pro","owner":{"login":"tnorthcutt","id":796639,"avatar_url":"https://avatars.githubusercontent.com/u/796639?v=3","gravatar_id":"","url":"https://api.github.com/users/tnorthcutt","html_url":"https://github.com/tnorthcutt","followers_url":"https://api.github.com/users/tnorthcutt/followers","following_url":"https://api.github.com/users/tnorthcutt/following{/other_user}","gists_url":"https://api.github.com/users/tnorthcutt/gists{/gist_id}","starred_url":"https://api.github.com/users/tnorthcutt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tnorthcutt/subscriptions","organizations_url":"https://api.github.com/users/tnorthcutt/orgs","repos_url":"https://api.github.com/users/tnorthcutt/repos","events_url":"https://api.github.com/users/tnorthcutt/events{/privacy}","received_events_url":"https://api.github.com/users/tnorthcutt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tnorthcutt/Restrict-Content-Pro","description":"Restrict Content Pro","fork":true,"url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro","forks_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/forks","keys_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/teams","hooks_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/hooks","issue_events_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/issues/events{/number}","events_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/events","assignees_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/assignees{/user}","branches_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/branches{/branch}","tags_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/tags","blobs_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/git/refs{/sha}","trees_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/statuses/{sha}","languages_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/languages","stargazers_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/stargazers","contributors_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/contributors","subscribers_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/subscribers","subscription_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/subscription","commits_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/commits{/sha}","git_commits_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/git/commits{/sha}","comments_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/comments{/number}","issue_comment_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/issues/comments{/number}","contents_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/contents/{+path}","compare_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/merges","archive_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/downloads","issues_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/issues{/number}","pulls_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/pulls{/number}","milestones_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/milestones{/number}","notifications_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/labels{/name}","releases_url":"https://api.github.com/repos/tnorthcutt/Restrict-Content-Pro/releases{/id}","created_at":"2014-12-14T20:33:06Z","updated_at":"2015-03-25T02:01:53Z","pushed_at":"2015-03-26T04:03:58Z","git_url":"git://github.com/tnorthcutt/Restrict-Content-Pro.git","ssh_url":"git@github.com:tnorthcutt/Restrict-Content-Pro.git","clone_url":"https://github.com/tnorthcutt/Restrict-Content-Pro.git","svn_url":"https://github.com/tnorthcutt/Restrict-Content-Pro","homepage":null,"size":6017,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"pippinsplugins:release/2.1","ref":"release/2.1","sha":"e39ddef72d41ea79eee51f6940a8db272e3cbe90","user":{"login":"pippinsplugins","id":1034109,"avatar_url":"https://avatars.githubusercontent.com/u/1034109?v=3","gravatar_id":"","url":"https://api.github.com/users/pippinsplugins","html_url":"https://github.com/pippinsplugins","followers_url":"https://api.github.com/users/pippinsplugins/followers","following_url":"https://api.github.com/users/pippinsplugins/following{/other_user}","gists_url":"https://api.github.com/users/pippinsplugins/gists{/gist_id}","starred_url":"https://api.github.com/users/pippinsplugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pippinsplugins/subscriptions","organizations_url":"https://api.github.com/users/pippinsplugins/orgs","repos_url":"https://api.github.com/users/pippinsplugins/repos","events_url":"https://api.github.com/users/pippinsplugins/events{/privacy}","received_events_url":"https://api.github.com/users/pippinsplugins/received_events","type":"User","site_admin":false},"repo":{"id":4341964,"name":"Restrict-Content-Pro","full_name":"pippinsplugins/Restrict-Content-Pro","owner":{"login":"pippinsplugins","id":1034109,"avatar_url":"https://avatars.githubusercontent.com/u/1034109?v=3","gravatar_id":"","url":"https://api.github.com/users/pippinsplugins","html_url":"https://github.com/pippinsplugins","followers_url":"https://api.github.com/users/pippinsplugins/followers","following_url":"https://api.github.com/users/pippinsplugins/following{/other_user}","gists_url":"https://api.github.com/users/pippinsplugins/gists{/gist_id}","starred_url":"https://api.github.com/users/pippinsplugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pippinsplugins/subscriptions","organizations_url":"https://api.github.com/users/pippinsplugins/orgs","repos_url":"https://api.github.com/users/pippinsplugins/repos","events_url":"https://api.github.com/users/pippinsplugins/events{/privacy}","received_events_url":"https://api.github.com/users/pippinsplugins/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pippinsplugins/Restrict-Content-Pro","description":"Restrict Content Pro","fork":false,"url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro","forks_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/forks","keys_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/teams","hooks_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/hooks","issue_events_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/events{/number}","events_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/events","assignees_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/assignees{/user}","branches_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/branches{/branch}","tags_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/tags","blobs_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/git/refs{/sha}","trees_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/statuses/{sha}","languages_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/languages","stargazers_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/stargazers","contributors_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/contributors","subscribers_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/subscribers","subscription_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/subscription","commits_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/commits{/sha}","git_commits_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/git/commits{/sha}","comments_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/comments{/number}","issue_comment_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/comments{/number}","contents_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/contents/{+path}","compare_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/merges","archive_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/downloads","issues_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues{/number}","pulls_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls{/number}","milestones_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/milestones{/number}","notifications_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/labels{/name}","releases_url":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/releases{/id}","created_at":"2012-05-16T00:11:56Z","updated_at":"2015-03-11T04:08:02Z","pushed_at":"2015-03-26T04:04:48Z","git_url":"git://github.com/pippinsplugins/Restrict-Content-Pro.git","ssh_url":"git@github.com:pippinsplugins/Restrict-Content-Pro.git","clone_url":"https://github.com/pippinsplugins/Restrict-Content-Pro.git","svn_url":"https://github.com/pippinsplugins/Restrict-Content-Pro","homepage":null,"size":7950,"stargazers_count":55,"watchers_count":55,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":8,"mirror_url":null,"open_issues_count":26,"forks":8,"open_issues":26,"watchers":55,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138"},"html":{"href":"https://github.com/pippinsplugins/Restrict-Content-Pro/pull/138"},"issue":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/138"},"comments":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/issues/138/comments"},"review_comments":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138/comments"},"review_comment":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/pulls/138/commits"},"statuses":{"href":"https://api.github.com/repos/pippinsplugins/Restrict-Content-Pro/statuses/ddc0cccd9f11f469a6939198dadb47397fabd07f"}}}}