diff options
| author | user@node5.net <user@node5.net> | 2026-06-15 21:37:15 +0200 |
|---|---|---|
| committer | user@node5.net <user@node5.net> | 2026-06-15 21:37:15 +0200 |
| commit | 6b305c19b43db80b72896f8e4d2f8976e79d3672 (patch) | |
| tree | 3e7223d474d8162ce56a796177a5961d126fa996 /src | |
| parent | 38b8178cce160b3d2e6c8b3256c7655f4d0a27cd (diff) | |
don't require telegram for comments
Diffstat (limited to 'src')
| -rw-r--r-- | src/blog_node5_net.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/blog_node5_net.py b/src/blog_node5_net.py index 94a1872..7857a85 100644 --- a/src/blog_node5_net.py +++ b/src/blog_node5_net.py @@ -157,7 +157,8 @@ def post_comment(): if key == 'contact' and not args['show_contact']: continue # Skip contact, if not public for privacy notification_message += f'\n{key[0].upper()}{key[1:]}: {args.get(key)}' - telegram.send_message(notification_message) + if 'telegram' in locals(): + telegram.send_message(notification_message) db.post_comment(**args) return flask.redirect(flask.request.referrer) |
