{"action":"created","comment":{"url":"https://api.github.com/repos/hapijs/bell/pulls/comments/25213407","id":25213407,"diff_hunk":"@@ -176,12 +176,17 @@ exports.v2 = function (settings) {\n             return reply(Boom.internal('Incorrect ' + name + ' state parameter'));\n         }\n \n+        var protocol = request.connection.info.protocol;\n+        if (settings.forceHttps) {\n+          protocol = 'https';","path":"lib/oauth.js","position":6,"original_position":6,"commit_id":"294a1b6cc4400b1074541f29b4791bb702dbc06e","original_commit_id":"294a1b6cc4400b1074541f29b4791bb702dbc06e","user":{"login":"geek","id":441346,"avatar_url":"https://avatars.githubusercontent.com/u/441346?v=3","gravatar_id":"","url":"https://api.github.com/users/geek","html_url":"https://github.com/geek","followers_url":"https://api.github.com/users/geek/followers","following_url":"https://api.github.com/users/geek/following{/other_user}","gists_url":"https://api.github.com/users/geek/gists{/gist_id}","starred_url":"https://api.github.com/users/geek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/geek/subscriptions","organizations_url":"https://api.github.com/users/geek/orgs","repos_url":"https://api.github.com/users/geek/repos","events_url":"https://api.github.com/users/geek/events{/privacy}","received_events_url":"https://api.github.com/users/geek/received_events","type":"User","site_admin":false},"body":"we are somewhat in the minority on this, but we use 4 spaces.","created_at":"2015-02-23T23:19:54Z","updated_at":"2015-02-23T23:19:54Z","html_url":"https://github.com/hapijs/bell/pull/60#discussion_r25213407","pull_request_url":"https://api.github.com/repos/hapijs/bell/pulls/60","_links":{"self":{"href":"https://api.github.com/repos/hapijs/bell/pulls/comments/25213407"},"html":{"href":"https://github.com/hapijs/bell/pull/60#discussion_r25213407"},"pull_request":{"href":"https://api.github.com/repos/hapijs/bell/pulls/60"}}},"pull_request":{"url":"https://api.github.com/repos/hapijs/bell/pulls/60","id":29750744,"html_url":"https://github.com/hapijs/bell/pull/60","diff_url":"https://github.com/hapijs/bell/pull/60.diff","patch_url":"https://github.com/hapijs/bell/pull/60.patch","issue_url":"https://api.github.com/repos/hapijs/bell/issues/60","number":60,"state":"open","locked":false,"title":"Make forceHttps complete ","user":{"login":"dapus","id":381101,"avatar_url":"https://avatars.githubusercontent.com/u/381101?v=3","gravatar_id":"","url":"https://api.github.com/users/dapus","html_url":"https://github.com/dapus","followers_url":"https://api.github.com/users/dapus/followers","following_url":"https://api.github.com/users/dapus/following{/other_user}","gists_url":"https://api.github.com/users/dapus/gists{/gist_id}","starred_url":"https://api.github.com/users/dapus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dapus/subscriptions","organizations_url":"https://api.github.com/users/dapus/orgs","repos_url":"https://api.github.com/users/dapus/repos","events_url":"https://api.github.com/users/dapus/events{/privacy}","received_events_url":"https://api.github.com/users/dapus/received_events","type":"User","site_admin":false},"body":"`redirect_uri` is sent to the provider a second time. This code forces https (if option is set) in that case as well.","created_at":"2015-02-21T08:19:05Z","updated_at":"2015-02-23T23:19:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f05296834d0df986df28e812f60093ba37ef0eeb","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/hapijs/bell/pulls/60/commits","review_comments_url":"https://api.github.com/repos/hapijs/bell/pulls/60/comments","review_comment_url":"https://api.github.com/repos/hapijs/bell/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hapijs/bell/issues/60/comments","statuses_url":"https://api.github.com/repos/hapijs/bell/statuses/294a1b6cc4400b1074541f29b4791bb702dbc06e","head":{"label":"dapus:master","ref":"master","sha":"294a1b6cc4400b1074541f29b4791bb702dbc06e","user":{"login":"dapus","id":381101,"avatar_url":"https://avatars.githubusercontent.com/u/381101?v=3","gravatar_id":"","url":"https://api.github.com/users/dapus","html_url":"https://github.com/dapus","followers_url":"https://api.github.com/users/dapus/followers","following_url":"https://api.github.com/users/dapus/following{/other_user}","gists_url":"https://api.github.com/users/dapus/gists{/gist_id}","starred_url":"https://api.github.com/users/dapus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dapus/subscriptions","organizations_url":"https://api.github.com/users/dapus/orgs","repos_url":"https://api.github.com/users/dapus/repos","events_url":"https://api.github.com/users/dapus/events{/privacy}","received_events_url":"https://api.github.com/users/dapus/received_events","type":"User","site_admin":false},"repo":{"id":31074853,"name":"bell","full_name":"dapus/bell","owner":{"login":"dapus","id":381101,"avatar_url":"https://avatars.githubusercontent.com/u/381101?v=3","gravatar_id":"","url":"https://api.github.com/users/dapus","html_url":"https://github.com/dapus","followers_url":"https://api.github.com/users/dapus/followers","following_url":"https://api.github.com/users/dapus/following{/other_user}","gists_url":"https://api.github.com/users/dapus/gists{/gist_id}","starred_url":"https://api.github.com/users/dapus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dapus/subscriptions","organizations_url":"https://api.github.com/users/dapus/orgs","repos_url":"https://api.github.com/users/dapus/repos","events_url":"https://api.github.com/users/dapus/events{/privacy}","received_events_url":"https://api.github.com/users/dapus/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dapus/bell","description":"Third-party login plugin for hapi","fork":true,"url":"https://api.github.com/repos/dapus/bell","forks_url":"https://api.github.com/repos/dapus/bell/forks","keys_url":"https://api.github.com/repos/dapus/bell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dapus/bell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dapus/bell/teams","hooks_url":"https://api.github.com/repos/dapus/bell/hooks","issue_events_url":"https://api.github.com/repos/dapus/bell/issues/events{/number}","events_url":"https://api.github.com/repos/dapus/bell/events","assignees_url":"https://api.github.com/repos/dapus/bell/assignees{/user}","branches_url":"https://api.github.com/repos/dapus/bell/branches{/branch}","tags_url":"https://api.github.com/repos/dapus/bell/tags","blobs_url":"https://api.github.com/repos/dapus/bell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dapus/bell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dapus/bell/git/refs{/sha}","trees_url":"https://api.github.com/repos/dapus/bell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dapus/bell/statuses/{sha}","languages_url":"https://api.github.com/repos/dapus/bell/languages","stargazers_url":"https://api.github.com/repos/dapus/bell/stargazers","contributors_url":"https://api.github.com/repos/dapus/bell/contributors","subscribers_url":"https://api.github.com/repos/dapus/bell/subscribers","subscription_url":"https://api.github.com/repos/dapus/bell/subscription","commits_url":"https://api.github.com/repos/dapus/bell/commits{/sha}","git_commits_url":"https://api.github.com/repos/dapus/bell/git/commits{/sha}","comments_url":"https://api.github.com/repos/dapus/bell/comments{/number}","issue_comment_url":"https://api.github.com/repos/dapus/bell/issues/comments{/number}","contents_url":"https://api.github.com/repos/dapus/bell/contents/{+path}","compare_url":"https://api.github.com/repos/dapus/bell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dapus/bell/merges","archive_url":"https://api.github.com/repos/dapus/bell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dapus/bell/downloads","issues_url":"https://api.github.com/repos/dapus/bell/issues{/number}","pulls_url":"https://api.github.com/repos/dapus/bell/pulls{/number}","milestones_url":"https://api.github.com/repos/dapus/bell/milestones{/number}","notifications_url":"https://api.github.com/repos/dapus/bell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dapus/bell/labels{/name}","releases_url":"https://api.github.com/repos/dapus/bell/releases{/id}","created_at":"2015-02-20T17:01:04Z","updated_at":"2015-02-20T18:19:50Z","pushed_at":"2015-02-20T18:19:50Z","git_url":"git://github.com/dapus/bell.git","ssh_url":"git@github.com:dapus/bell.git","clone_url":"https://github.com/dapus/bell.git","svn_url":"https://github.com/dapus/bell","homepage":null,"size":295,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"hapijs:master","ref":"master","sha":"769e218b0627c30d63387b1f0813325096814f37","user":{"login":"hapijs","id":3774533,"avatar_url":"https://avatars.githubusercontent.com/u/3774533?v=3","gravatar_id":"","url":"https://api.github.com/users/hapijs","html_url":"https://github.com/hapijs","followers_url":"https://api.github.com/users/hapijs/followers","following_url":"https://api.github.com/users/hapijs/following{/other_user}","gists_url":"https://api.github.com/users/hapijs/gists{/gist_id}","starred_url":"https://api.github.com/users/hapijs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hapijs/subscriptions","organizations_url":"https://api.github.com/users/hapijs/orgs","repos_url":"https://api.github.com/users/hapijs/repos","events_url":"https://api.github.com/users/hapijs/events{/privacy}","received_events_url":"https://api.github.com/users/hapijs/received_events","type":"Organization","site_admin":false},"repo":{"id":20395079,"name":"bell","full_name":"hapijs/bell","owner":{"login":"hapijs","id":3774533,"avatar_url":"https://avatars.githubusercontent.com/u/3774533?v=3","gravatar_id":"","url":"https://api.github.com/users/hapijs","html_url":"https://github.com/hapijs","followers_url":"https://api.github.com/users/hapijs/followers","following_url":"https://api.github.com/users/hapijs/following{/other_user}","gists_url":"https://api.github.com/users/hapijs/gists{/gist_id}","starred_url":"https://api.github.com/users/hapijs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hapijs/subscriptions","organizations_url":"https://api.github.com/users/hapijs/orgs","repos_url":"https://api.github.com/users/hapijs/repos","events_url":"https://api.github.com/users/hapijs/events{/privacy}","received_events_url":"https://api.github.com/users/hapijs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hapijs/bell","description":"Third-party login plugin for hapi","fork":false,"url":"https://api.github.com/repos/hapijs/bell","forks_url":"https://api.github.com/repos/hapijs/bell/forks","keys_url":"https://api.github.com/repos/hapijs/bell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hapijs/bell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hapijs/bell/teams","hooks_url":"https://api.github.com/repos/hapijs/bell/hooks","issue_events_url":"https://api.github.com/repos/hapijs/bell/issues/events{/number}","events_url":"https://api.github.com/repos/hapijs/bell/events","assignees_url":"https://api.github.com/repos/hapijs/bell/assignees{/user}","branches_url":"https://api.github.com/repos/hapijs/bell/branches{/branch}","tags_url":"https://api.github.com/repos/hapijs/bell/tags","blobs_url":"https://api.github.com/repos/hapijs/bell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hapijs/bell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hapijs/bell/git/refs{/sha}","trees_url":"https://api.github.com/repos/hapijs/bell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hapijs/bell/statuses/{sha}","languages_url":"https://api.github.com/repos/hapijs/bell/languages","stargazers_url":"https://api.github.com/repos/hapijs/bell/stargazers","contributors_url":"https://api.github.com/repos/hapijs/bell/contributors","subscribers_url":"https://api.github.com/repos/hapijs/bell/subscribers","subscription_url":"https://api.github.com/repos/hapijs/bell/subscription","commits_url":"https://api.github.com/repos/hapijs/bell/commits{/sha}","git_commits_url":"https://api.github.com/repos/hapijs/bell/git/commits{/sha}","comments_url":"https://api.github.com/repos/hapijs/bell/comments{/number}","issue_comment_url":"https://api.github.com/repos/hapijs/bell/issues/comments{/number}","contents_url":"https://api.github.com/repos/hapijs/bell/contents/{+path}","compare_url":"https://api.github.com/repos/hapijs/bell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hapijs/bell/merges","archive_url":"https://api.github.com/repos/hapijs/bell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hapijs/bell/downloads","issues_url":"https://api.github.com/repos/hapijs/bell/issues{/number}","pulls_url":"https://api.github.com/repos/hapijs/bell/pulls{/number}","milestones_url":"https://api.github.com/repos/hapijs/bell/milestones{/number}","notifications_url":"https://api.github.com/repos/hapijs/bell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hapijs/bell/labels{/name}","releases_url":"https://api.github.com/repos/hapijs/bell/releases{/id}","created_at":"2014-06-02T06:34:28Z","updated_at":"2015-02-19T00:59:51Z","pushed_at":"2015-02-02T23:00:28Z","git_url":"git://github.com/hapijs/bell.git","ssh_url":"git@github.com:hapijs/bell.git","clone_url":"https://github.com/hapijs/bell.git","svn_url":"https://github.com/hapijs/bell","homepage":null,"size":739,"stargazers_count":136,"watchers_count":136,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":45,"mirror_url":null,"open_issues_count":12,"forks":45,"open_issues":12,"watchers":136,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hapijs/bell/pulls/60"},"html":{"href":"https://github.com/hapijs/bell/pull/60"},"issue":{"href":"https://api.github.com/repos/hapijs/bell/issues/60"},"comments":{"href":"https://api.github.com/repos/hapijs/bell/issues/60/comments"},"review_comments":{"href":"https://api.github.com/repos/hapijs/bell/pulls/60/comments"},"review_comment":{"href":"https://api.github.com/repos/hapijs/bell/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hapijs/bell/pulls/60/commits"},"statuses":{"href":"https://api.github.com/repos/hapijs/bell/statuses/294a1b6cc4400b1074541f29b4791bb702dbc06e"}}}}