From a6cbabfba5c46612ba6281878b6c434522c3cb66 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Tue, 9 Apr 2024 08:45:37 +0200 Subject: [PATCH] Add server connection validation in CheckProxy.php --- app/Actions/Proxy/CheckProxy.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/Actions/Proxy/CheckProxy.php b/app/Actions/Proxy/CheckProxy.php index 32a4897a6..d39b33a2a 100644 --- a/app/Actions/Proxy/CheckProxy.php +++ b/app/Actions/Proxy/CheckProxy.php @@ -13,6 +13,9 @@ public function handle(Server $server, $fromUI = false) if ($server->proxyType() === 'NONE') { return false; } + if (!$server->validateConnection()) { + throw new \Exception("Server Connection Error"); + } if (!$server->isProxyShouldRun()) { if ($fromUI) { throw new \Exception("Proxy should not run. You selected the Custom Proxy.");