fix: 🐛 update log style

This commit is contained in:
jqtmviyu 2024-07-31 06:08:08 +08:00
parent db53b95798
commit 8cc5a89cd8
2 changed files with 2 additions and 2 deletions

View File

@ -243,7 +243,7 @@ echo "$ips" | while IFS= read -r line; do
echo_pass "$ip 是私有地址, 忽略."
else
# 添加规则
[ "$DEBUG" -eq 0 ] && echo -e "$(date '+%Y-%m-%d %H:%M:%S')\t$client\t$ip\n" >>$log_path
[ "$DEBUG" -eq 0 ] && echo -e "$(date '+%Y-%m-%d %H:%M:%S')\t$client\t$ip" >>$log_path
if echo "$ip" | grep -q ":"; then
echo_err "添加IPv6地址 $ip 到自定义链 $custom_chain_ipv6"
[ "$DEBUG" -eq 0 ] && ip6tables -I $custom_chain_ipv6 -d $ip -j DROP

View File

@ -201,7 +201,7 @@ echo "$block_clients" | while IFS= read -r client; do
debug_echo "$ip 是私有地址, 忽略."
else
# 添加规则
[ "$DEBUG" -eq 0 ] && echo -e "$client\t\t$ip\t\t$(date '+%Y-%m-%d %H:%M:%S')\n" >>$log_path
[ "$DEBUG" -eq 0 ] && echo -e "$(date '+%Y-%m-%d %H:%M:%S')\t$client\t$ip" >>$log_path
if echo "$ip" | grep -q ":"; then
debug_echo "添加IPv6地址 $ip 到自定义链 $custom_chain_ipv6"
[ "$DEBUG" -eq 0 ] && ip6tables -I $custom_chain_ipv6 -d $ip -j DROP