parameter('country') ?? wu_request('billing_country'); $state = $this->parameter('state') ?? wu_request('billing_state'); if ($country && $state && $city) { $state = strtoupper((string) $state); $allowed_cities = wu_get_country_cities(strtoupper((string) $country), $state, false); if (! empty($allowed_cities)) { $check = in_array($city, $allowed_cities, true); } } return $check; } }