From 13b1ab4aac7f2e36db59f6c50463ccc5fc80a16b Mon Sep 17 00:00:00 2001 From: jxxghp Date: Fri, 9 Jun 2023 18:15:00 +0800 Subject: [PATCH] fix --- app/utils/string.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/utils/string.py b/app/utils/string.py index 8759e99e..f5c7ae14 100644 --- a/app/utils/string.py +++ b/app/utils/string.py @@ -536,6 +536,8 @@ class StringUtils: """ 从地址中获取域名和端口号 """ + if not address: + return None, None if not address.startswith("http"): address = "http://" + address parts = address.split(":")