We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bdd215f commit 4a9a6c1Copy full SHA for 4a9a6c1
includes/Generator/CustomerInfo.php
@@ -16,7 +16,7 @@ class CustomerInfo {
16
* @return string|\WP_Error
17
*/
18
public static function get_valid_country_code( ?string $country_code = '' ) {
19
- $country_code = strtoupper( $country_code );
+ $country_code = !empty( $country_code ) ? strtoupper( $country_code ) : '';
20
21
if ( $country_code && ! WC()->countries->country_exists( $country_code ) ) {
22
$country_code = new \WP_Error(
0 commit comments