Skip to content

Commit

Permalink
to array is now constructed as a combination of arguments rather them…
Browse files Browse the repository at this point in the history
… in isolation
  • Loading branch information
LordFarquaadtheCreator committed Sep 2, 2024
1 parent 5f1415d commit ba4fe6f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
with open(PATH, "r") as f:
html_string = f.read()

to = []

parser = argparse.ArgumentParser(
prog="BYTE Email Client",
description="Emails clients using database of current and previous BYTE applicants. Takes body from body.html. Defaults to emailing all in database regardless of active member",
Expand All @@ -32,14 +34,14 @@
from Database import Database

d = Database()
to = d.get_cabinet()
to.append(*d.get_cabinet())

if isinstance(args.active, bool) and args.active:
from Database import Database

d = Database()
to = d.get_active()
to.append(*d.get_active())

to = ["fahadfaruqi1@gmail.com"] # testing only
to.append("fahadfaruqi1@gmail.com") # testing only
e = Email(html_string, args.subject, to)
e.email()

0 comments on commit ba4fe6f

Please sign in to comment.