findByCode static method
Returns a Country by its name code
Throws an exception if the country could not be found
Implementation
static Country findByCode(String code) {
return _list.firstWhere(
(country) => country.code == code,
orElse: () {
throw CountryNotFoundException(code);
},
);
}