Create message before calling send_message function

This commit is contained in:
Stewie
2022-05-21 23:09:50 -04:00
parent ac2eb31869
commit 00895f800a
2 changed files with 8 additions and 7 deletions

View File

@@ -31,15 +31,10 @@ def get_credentials(): # Gets valid user credentials from disk.
return credentials
def send_message(sender, to, commiter_name, subject, xdelta_link):
def send_message(sender, to, subject, xdelta_link, message_text):
message_text = """
Hi {},
here is your xdelta patch :
{}
""".format(commiter_name, xdelta_link)
credentials = get_credentials()
#print (credentials)

View File

@@ -216,7 +216,13 @@ if __name__ == "__main__":
file_link = GoogleAPI.upload_xdelta(xdelta_name, "Stewie") #Need to add user for the folder
GoogleAPI.send_message('fortiersteven1@gmail.com', 'fortiersteven1@gmail.com', "Stewie", game_name + " Patch", file_link)
message_text = """
Hi {},
here is your xdelta patch :
{}
""".format('fortiersteven1@gmail.com', file_link)
GoogleAPI.send_message('fortiersteven1@gmail.com', 'fortiersteven1@gmail.com', game_name + " Patch", file_link)