Hotfix: Prevent masquerade enable when webpanel active

This commit is contained in:
Whispering Wind
2025-02-15 23:46:00 +03:30
committed by GitHub
parent 7df069d638
commit d9483a8b76

View File

@ -754,12 +754,16 @@ masquerade_handler() {
case $option in case $option in
1) 1)
if systemctl is-active --quiet hysteria-webpanel.service; then
echo -e "${red}Error:${NC} Masquerade cannot be enabled because hysteria-webpanel.service is running."
else
read -p "Enter the URL for rewriteHost: " url read -p "Enter the URL for rewriteHost: " url
if [ -z "$url" ]; then if [ -z "$url" ]; then
echo "Error: URL cannot be empty. Please try again." echo "Error: URL cannot be empty. Please try again."
else else
python3 $CLI_PATH masquerade -e "$url" python3 $CLI_PATH masquerade -e "$url"
fi fi
fi
;; ;;
2) 2)
python3 $CLI_PATH masquerade -r python3 $CLI_PATH masquerade -r