From 102bce359d6317bf3c1a4606f57d7a4384a1b8d2 Mon Sep 17 00:00:00 2001 From: D4708 Date: Sun, 30 May 2021 14:43:32 +0300 Subject: [PATCH] remove extra code --- tor.php | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/tor.php b/tor.php index 18105e6..82292e5 100644 --- a/tor.php +++ b/tor.php @@ -14,19 +14,13 @@ $curlTorProject = new CurlTorProject(TORPROJECT_PROTOCOL, TORPROJECT_HOST, TORPR $modelIp = new ModelIp(DB_DATABASE, DB_HOSTNAME, DB_PORT, DB_USERNAME, DB_PASSWORD); $modelLog = new ModelLog(DB_DATABASE, DB_HOSTNAME, DB_PORT, DB_USERNAME, DB_PASSWORD); -$exitNodes = []; - // Get TOR registry if ($torProjectExitNodes = $curlTorProject->getExitNodes()) { - foreach ($torProjectExitNodes as $exitNode) { - $exitNodes[] = $exitNode; - } - // Get IPs foreach ($modelIp->getIps() as $ip) { - if (in_array($ip['address'], $exitNodes)) { + if (in_array($ip['address'], $torProjectExitNodes)) { $modelIp->setIsTOR($ip['ipId']); } }