diff --git a/modules/scheduled.py b/modules/scheduled.py index ae73e04..3da6b8d 100644 --- a/modules/scheduled.py +++ b/modules/scheduled.py @@ -62,9 +62,10 @@ if configGet("enabled", "scheduler", "sponsorships"): holo_user = HoloUser(entry["user"]) await app.send_message( entry["user"], locale("sponsorships_expired", "message") ) # type: ignore await holo_user.label_reset(configGet("destination_group")) + col_sponsorships.find_one_and_delete({"user": holo_user.id}) try: tg_user = await app.get_users(entry["user"]) - logWrite(f"Notified user that sponsorship expires in {until_expiry} days") + logWrite(f"Notified user that sponsorship expired") except Exception as exp: logWrite(f"Could not find user {entry['user']} notify about sponsorship expired due to '{exp}'") except Exception as exp: