mirror of
https://github.com/quantum5/qlinks.git
synced 2025-04-24 10:41:57 -04:00
Implement broken link email handling
This commit is contained in:
parent
637069c4e7
commit
35240c990f
|
@ -51,6 +51,7 @@ class Command(BaseCommand):
|
||||||
link.check_url()
|
link.check_url()
|
||||||
if was_working and not link.is_working:
|
if was_working and not link.is_working:
|
||||||
self.stdout.write(f'URL for {link.short} just broke: {link.long}')
|
self.stdout.write(f'URL for {link.short} just broke: {link.long}')
|
||||||
|
if settings.QLINKS_BROKEN_EMAIL:
|
||||||
send_broken_email(link)
|
send_broken_email(link)
|
||||||
|
|
||||||
time.sleep(settings.QLINKS_CHECK_THROTTLE)
|
time.sleep(settings.QLINKS_CHECK_THROTTLE)
|
||||||
|
|
Loading…
Reference in a new issue