From d2ee9c1ab93e4a6f667aa5be3766b41dad6a1fa4 Mon Sep 17 00:00:00 2001 From: Anes Belfodil Date: Mon, 9 Dec 2024 15:45:44 -0500 Subject: [PATCH] Test --- connection.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/connection.py b/connection.py index 37438df..449940b 100644 --- a/connection.py +++ b/connection.py @@ -5,8 +5,8 @@ logger = get_logger(__name__) def _is_connected(): + urlopen(Request("https://1.1.1.1", headers={"User-Agent": "randwall/1.0"})) try: - urlopen(Request("https://1.1.1.1", headers={"User-Agent": "randwall/1.0"})) return True except: logger.warning("Failed to connect to the internet.")