added condition to check for selected shipping country in case its undefined