From e07f400ed632fd1f9f89efaf33482762e6dfc3b4 Mon Sep 17 00:00:00 2001 From: SamNet-dev Date: Thu, 12 Feb 2026 15:08:58 -0600 Subject: [PATCH] fix: uninstall telegram service error and add MTProto port tip - Inline telegram_disable_service in uninstall() since the function is defined inside the MANAGEMENT heredoc and not available in the outer script scope - Add port forwarding tip on MTProto proxy settings page --- conduit.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/conduit.sh b/conduit.sh index 242ceea..3015949 100644 --- a/conduit.sh +++ b/conduit.sh @@ -1829,6 +1829,9 @@ show_mtproto_menu() { fi fi echo "" + echo -e " ${DIM}Tip: Port ${MTPROTO_PORT:-443} must be open on your firewall/security group.${NC}" + echo -e " ${DIM}If running at home, port-forward ${MTPROTO_PORT:-443} on your router.${NC}" + echo "" echo " Options:" echo " 1. Start" echo " 2. Stop" @@ -14940,7 +14943,11 @@ print_summary() { #═══════════════════════════════════════════════════════════════════════ uninstall() { - telegram_disable_service + # Stop and disable telegram service (inline — function is inside MANAGEMENT heredoc) + if command -v systemctl &>/dev/null && [ -f /etc/systemd/system/conduit-telegram.service ]; then + systemctl stop conduit-telegram.service 2>/dev/null || true + systemctl disable conduit-telegram.service 2>/dev/null || true + fi rm -f /etc/systemd/system/conduit-telegram.service 2>/dev/null systemctl daemon-reload 2>/dev/null || true echo ""