{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/comments/199256627","pull_request_review_id":133347637,"id":199256627,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5OTI1NjYyNw==","diff_hunk":"@@ -298,6 +298,10 @@ module.exports = function (log, config) {\n       headers: Object.keys(headers).join(',')\n     })\n \n+    if (config.emailService.forcedEmailAddresses.test(emailConfig.to)) {\n+        this.mailer = require('./email_service')(config)","path":"lib/senders/email.js","position":5,"original_position":5,"commit_id":"71dd839d357207eb9174bf4b4cd21df84c0ecd88","original_commit_id":"71dd839d357207eb9174bf4b4cd21df84c0ecd88","user":{"login":"brizental","id":25176023,"node_id":"MDQ6VXNlcjI1MTc2MDIz","avatar_url":"https://avatars2.githubusercontent.com/u/25176023?v=4","gravatar_id":"","url":"https://api.github.com/users/brizental","html_url":"https://github.com/brizental","followers_url":"https://api.github.com/users/brizental/followers","following_url":"https://api.github.com/users/brizental/following{/other_user}","gists_url":"https://api.github.com/users/brizental/gists{/gist_id}","starred_url":"https://api.github.com/users/brizental/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brizental/subscriptions","organizations_url":"https://api.github.com/users/brizental/orgs","repos_url":"https://api.github.com/users/brizental/repos","events_url":"https://api.github.com/users/brizental/events{/privacy}","received_events_url":"https://api.github.com/users/brizental/received_events","type":"User","site_admin":false},"body":"I tried to initialize it along with the rest of the stuff (specifically here: https://github.com/mozilla/fxa-auth-server/blob/71dd839d357207eb9174bf4b4cd21df84c0ecd88/lib/senders/email.js#L138), but the `config` there is different and doesnt have `emailService`. Is there a better way around it though? I also don't like my solution.","created_at":"2018-06-29T19:14:36Z","updated_at":"2018-06-29T19:14:36Z","html_url":"https://github.com/mozilla/fxa-auth-server/pull/2494#discussion_r199256627","pull_request_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/comments/199256627"},"html":{"href":"https://github.com/mozilla/fxa-auth-server/pull/2494#discussion_r199256627"},"pull_request":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494"}},"in_reply_to_id":199253533},"pull_request":{"url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494","id":198381243,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk4MzgxMjQz","html_url":"https://github.com/mozilla/fxa-auth-server/pull/2494","diff_url":"https://github.com/mozilla/fxa-auth-server/pull/2494.diff","patch_url":"https://github.com/mozilla/fxa-auth-server/pull/2494.patch","issue_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/2494","number":2494,"state":"open","locked":false,"title":"feat(email): use fxa-email-server for specific email addresses","user":{"login":"brizental","id":25176023,"node_id":"MDQ6VXNlcjI1MTc2MDIz","avatar_url":"https://avatars2.githubusercontent.com/u/25176023?v=4","gravatar_id":"","url":"https://api.github.com/users/brizental","html_url":"https://github.com/brizental","followers_url":"https://api.github.com/users/brizental/followers","following_url":"https://api.github.com/users/brizental/following{/other_user}","gists_url":"https://api.github.com/users/brizental/gists{/gist_id}","starred_url":"https://api.github.com/users/brizental/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brizental/subscriptions","organizations_url":"https://api.github.com/users/brizental/orgs","repos_url":"https://api.github.com/users/brizental/repos","events_url":"https://api.github.com/users/brizental/events{/privacy}","received_events_url":"https://api.github.com/users/brizental/received_events","type":"User","site_admin":false},"body":"Fixes #2411 \r\n\r\nThis is using fxa-email-service to send emails when the email matches the ` /emailservice.[A-Za-z0-9._%+-]+@restmail.net$/` pattern.\r\n\r\nr? @vladikoff @philbooth ","created_at":"2018-06-29T17:42:08Z","updated_at":"2018-06-29T19:14:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9d1177f0c14fb687dfe1213f75b704411565fe5a","assignee":{"login":"brizental","id":25176023,"node_id":"MDQ6VXNlcjI1MTc2MDIz","avatar_url":"https://avatars2.githubusercontent.com/u/25176023?v=4","gravatar_id":"","url":"https://api.github.com/users/brizental","html_url":"https://github.com/brizental","followers_url":"https://api.github.com/users/brizental/followers","following_url":"https://api.github.com/users/brizental/following{/other_user}","gists_url":"https://api.github.com/users/brizental/gists{/gist_id}","starred_url":"https://api.github.com/users/brizental/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brizental/subscriptions","organizations_url":"https://api.github.com/users/brizental/orgs","repos_url":"https://api.github.com/users/brizental/repos","events_url":"https://api.github.com/users/brizental/events{/privacy}","received_events_url":"https://api.github.com/users/brizental/received_events","type":"User","site_admin":false},"assignees":[{"login":"brizental","id":25176023,"node_id":"MDQ6VXNlcjI1MTc2MDIz","avatar_url":"https://avatars2.githubusercontent.com/u/25176023?v=4","gravatar_id":"","url":"https://api.github.com/users/brizental","html_url":"https://github.com/brizental","followers_url":"https://api.github.com/users/brizental/followers","following_url":"https://api.github.com/users/brizental/following{/other_user}","gists_url":"https://api.github.com/users/brizental/gists{/gist_id}","starred_url":"https://api.github.com/users/brizental/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brizental/subscriptions","organizations_url":"https://api.github.com/users/brizental/orgs","repos_url":"https://api.github.com/users/brizental/repos","events_url":"https://api.github.com/users/brizental/events{/privacy}","received_events_url":"https://api.github.com/users/brizental/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":346098910,"node_id":"MDU6TGFiZWwzNDYwOTg5MTA=","url":"https://api.github.com/repos/mozilla/fxa-auth-server/labels/waffle:active","name":"waffle:active","color":"ededed","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494/commits","review_comments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494/comments","review_comment_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/2494/comments","statuses_url":"https://api.github.com/repos/mozilla/fxa-auth-server/statuses/71dd839d357207eb9174bf4b4cd21df84c0ecd88","head":{"label":"mozilla:feature.emailservice2","ref":"feature.emailservice2","sha":"71dd839d357207eb9174bf4b4cd21df84c0ecd88","user":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":10041891,"node_id":"MDEwOlJlcG9zaXRvcnkxMDA0MTg5MQ==","name":"fxa-auth-server","full_name":"mozilla/fxa-auth-server","owner":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/fxa-auth-server","description":"The Firefox Accounts authentication server.","fork":false,"url":"https://api.github.com/repos/mozilla/fxa-auth-server","forks_url":"https://api.github.com/repos/mozilla/fxa-auth-server/forks","keys_url":"https://api.github.com/repos/mozilla/fxa-auth-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/fxa-auth-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/fxa-auth-server/teams","hooks_url":"https://api.github.com/repos/mozilla/fxa-auth-server/hooks","issue_events_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/fxa-auth-server/events","assignees_url":"https://api.github.com/repos/mozilla/fxa-auth-server/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/fxa-auth-server/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/fxa-auth-server/tags","blobs_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/fxa-auth-server/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/fxa-auth-server/languages","stargazers_url":"https://api.github.com/repos/mozilla/fxa-auth-server/stargazers","contributors_url":"https://api.github.com/repos/mozilla/fxa-auth-server/contributors","subscribers_url":"https://api.github.com/repos/mozilla/fxa-auth-server/subscribers","subscription_url":"https://api.github.com/repos/mozilla/fxa-auth-server/subscription","commits_url":"https://api.github.com/repos/mozilla/fxa-auth-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/fxa-auth-server/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/fxa-auth-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/fxa-auth-server/merges","archive_url":"https://api.github.com/repos/mozilla/fxa-auth-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/fxa-auth-server/downloads","issues_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/fxa-auth-server/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/fxa-auth-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/fxa-auth-server/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/fxa-auth-server/releases{/id}","deployments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/deployments","created_at":"2013-05-13T21:42:48Z","updated_at":"2018-06-28T21:08:01Z","pushed_at":"2018-06-29T17:42:09Z","git_url":"git://github.com/mozilla/fxa-auth-server.git","ssh_url":"git@github.com:mozilla/fxa-auth-server.git","clone_url":"https://github.com/mozilla/fxa-auth-server.git","svn_url":"https://github.com/mozilla/fxa-auth-server","homepage":"https://wiki.mozilla.org/Identity/Firefox_Accounts","size":12751,"stargazers_count":343,"watchers_count":343,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":102,"mirror_url":null,"archived":false,"open_issues_count":55,"license":{"key":"mpl-2.0","name":"Mozilla Public License 2.0","spdx_id":"MPL-2.0","url":"https://api.github.com/licenses/mpl-2.0","node_id":"MDc6TGljZW5zZTE0"},"forks":102,"open_issues":55,"watchers":343,"default_branch":"master"}},"base":{"label":"mozilla:master","ref":"master","sha":"ed9c6a0962f0325633ca8d8920fadcee4c5e7c77","user":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":10041891,"node_id":"MDEwOlJlcG9zaXRvcnkxMDA0MTg5MQ==","name":"fxa-auth-server","full_name":"mozilla/fxa-auth-server","owner":{"login":"mozilla","id":131524,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzMTUyNA==","avatar_url":"https://avatars2.githubusercontent.com/u/131524?v=4","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/fxa-auth-server","description":"The Firefox Accounts authentication server.","fork":false,"url":"https://api.github.com/repos/mozilla/fxa-auth-server","forks_url":"https://api.github.com/repos/mozilla/fxa-auth-server/forks","keys_url":"https://api.github.com/repos/mozilla/fxa-auth-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/fxa-auth-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/fxa-auth-server/teams","hooks_url":"https://api.github.com/repos/mozilla/fxa-auth-server/hooks","issue_events_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/fxa-auth-server/events","assignees_url":"https://api.github.com/repos/mozilla/fxa-auth-server/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/fxa-auth-server/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/fxa-auth-server/tags","blobs_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/fxa-auth-server/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/fxa-auth-server/languages","stargazers_url":"https://api.github.com/repos/mozilla/fxa-auth-server/stargazers","contributors_url":"https://api.github.com/repos/mozilla/fxa-auth-server/contributors","subscribers_url":"https://api.github.com/repos/mozilla/fxa-auth-server/subscribers","subscription_url":"https://api.github.com/repos/mozilla/fxa-auth-server/subscription","commits_url":"https://api.github.com/repos/mozilla/fxa-auth-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/fxa-auth-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/fxa-auth-server/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/fxa-auth-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/fxa-auth-server/merges","archive_url":"https://api.github.com/repos/mozilla/fxa-auth-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/fxa-auth-server/downloads","issues_url":"https://api.github.com/repos/mozilla/fxa-auth-server/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/fxa-auth-server/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/fxa-auth-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/fxa-auth-server/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/fxa-auth-server/releases{/id}","deployments_url":"https://api.github.com/repos/mozilla/fxa-auth-server/deployments","created_at":"2013-05-13T21:42:48Z","updated_at":"2018-06-28T21:08:01Z","pushed_at":"2018-06-29T17:42:09Z","git_url":"git://github.com/mozilla/fxa-auth-server.git","ssh_url":"git@github.com:mozilla/fxa-auth-server.git","clone_url":"https://github.com/mozilla/fxa-auth-server.git","svn_url":"https://github.com/mozilla/fxa-auth-server","homepage":"https://wiki.mozilla.org/Identity/Firefox_Accounts","size":12751,"stargazers_count":343,"watchers_count":343,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":102,"mirror_url":null,"archived":false,"open_issues_count":55,"license":{"key":"mpl-2.0","name":"Mozilla Public License 2.0","spdx_id":"MPL-2.0","url":"https://api.github.com/licenses/mpl-2.0","node_id":"MDc6TGljZW5zZTE0"},"forks":102,"open_issues":55,"watchers":343,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494"},"html":{"href":"https://github.com/mozilla/fxa-auth-server/pull/2494"},"issue":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/2494"},"comments":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/issues/2494/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/pulls/2494/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla/fxa-auth-server/statuses/71dd839d357207eb9174bf4b4cd21df84c0ecd88"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"brizental"}}