Sponsorship auto-generate v0.1.40

This commit is contained in:
Jokob-sk
2024-01-28 22:37:44 +11:00
parent 1c87fb1284
commit 8e603fd5f9
3 changed files with 6 additions and 25 deletions

View File

@@ -72,10 +72,10 @@ def fetch_sponsors():
}
# Check if the sponsorship is current or past
if privacy_level == "PUBLIC":
current_sponsors.append(sponsor)
else:
if created_at == sponsorship["createdAt"]:
past_sponsors.append(sponsor)
else:
current_sponsors.append(sponsor)
print("Current Sponsors:")
print(current_sponsors)
@@ -85,6 +85,7 @@ def fetch_sponsors():
return {"current_sponsors": current_sponsors, "past_sponsors": past_sponsors}
def generate_sponsors_table(current_sponsors, past_sponsors):
current_table = "| Current Sponsors |\n|---|\n"
for sponsor in current_sponsors: