echo "Unable to create HTTP client" . PHP_EOL;
        exit;
    }
    // We know we have to iterate at least once, so use do... while
    do {
        // Get the current batch of requests
        $threads = array_splice($requests, 0, $config['threads']);
        // Create a new HttpRequestPool and attach the requests
        $pool = new \HttpRequestPool();
        foreach ($threads as $request) {
            $pool->attach($request);
        }
        // Send the requests and wait till they are all complete
        try {
            $pool->send();
            while (sizeof($pool->getFinishedRequests()) < sizeof($threads)) {
            }
            foreach ($pool as $request) {
                // Display progress
                if ($request->getResponseCode() == 200) {
                    echo '.';
                } else {
                    unset($config['urls'][$request->key]);
                    echo '!';
                }
            }
        } catch (\HttpRequestPoolException $e) {
        }
    } while (sizeof($requests) > 0);
} else {
    foreach ($config['urls'] as $key => $url) {