Skip to content

Commit 6086225

Browse files
chenyumicleahecole
chenyumic
andauthored
fix: update app engine standard mail sample to use the correct address format (#3096)
Co-authored-by: Leah E. Cole <[email protected]>
1 parent 5a37c65 commit 6086225

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

appengine/standard/mail/attachment.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
class AttachmentHandler(webapp2.RequestHandler):
2222
def post(self):
2323
f = self.request.POST['file']
24-
mail.send_mail(sender='{}@appspot.gserviceaccount.com'.format(
24+
mail.send_mail(sender='example@{}.appspotmail.com'.format(
2525
app_identity.get_application_id()),
2626
to="Albert Johnson <[email protected]>",
2727
subject="The doc you requested",

appengine/standard/mail/header.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def get(self):
4343
def post(self):
4444
print(repr(self.request.POST))
4545
id = self.request.POST['thread_id']
46-
send_example_mail('{}@appspot.gserviceaccount.com'.format(
46+
send_example_mail('example@{}.appspotmail.com'.format(
4747
app_identity.get_application_id()), id)
4848
self.response.content_type = 'text/plain'
4949
self.response.write(

appengine/standard/mail/send_mail.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def send_approved_mail(sender_address):
3737

3838
class SendMailHandler(webapp2.RequestHandler):
3939
def get(self):
40-
send_approved_mail('{}@appspot.gserviceaccount.com'.format(
40+
send_approved_mail('example@{}.appspotmail.com'.format(
4141
app_identity.get_application_id()))
4242
self.response.content_type = 'text/plain'
4343
self.response.write('Sent an email to Albert.')

appengine/standard/mail/send_message.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def send_approved_mail(sender_address):
4040

4141
class SendMessageHandler(webapp2.RequestHandler):
4242
def get(self):
43-
send_approved_mail('{}@appspot.gserviceaccount.com'.format(
43+
send_approved_mail('example@{}.appspotmail.com'.format(
4444
app_identity.get_application_id()))
4545
self.response.content_type = 'text/plain'
4646
self.response.write('Sent an email message to Albert.')

appengine/standard/mail/user_signup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def post(self):
3535
else:
3636
confirmation_url = create_new_user_confirmation(user_address)
3737
sender_address = (
38-
'Example.com Support <{}@appspot.gserviceaccount.com>'.format(
38+
'Example.com Support <example@{}.appspotmail.com>'.format(
3939
app_identity.get_application_id()))
4040
subject = 'Confirm your registration'
4141
body = """Thank you for creating an account!

0 commit comments

Comments
 (0)