From 484820f3241e8465172a05830f69bb3518b3beb2 Mon Sep 17 00:00:00 2001 From: billz Date: Sat, 10 Aug 2024 19:25:54 +0200 Subject: [PATCH] Update parsing of NordVPN countries, fixes #1634 --- includes/provider.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/includes/provider.php b/includes/provider.php index 4bafe8eee..c2ceb1a3c 100755 --- a/includes/provider.php +++ b/includes/provider.php @@ -102,7 +102,7 @@ function DisplayProviderConfig() } /** - * Validates VPN provider settings + * Validates VPN provider settings * * @param object $status * @param string $binPath @@ -240,11 +240,9 @@ function getCountries($id, $binPath) } break; case 3: // nordvpn - $output = stripArtifacts($output,'\s'); $arrTmp = explode(",", $output[0]); - $countries = array_combine($arrTmp, $arrTmp); - foreach ($countries as $key => $value) { - $countries[$key] = str_replace("_", " ", $value); + foreach ($output as $key => $value) { + $countries[$value] = str_replace("_", " ", $value); } break; default: