getSiDoNameFromCode function

String getSiDoNameFromCode({
  1. required String code,
  2. String languageCode = 'ko',
})

Returns the name of the Si/Do area code from the code.

If somehow the code is not found, it throws an exception.

Implementation

String getSiDoNameFromCode({required String code, String languageCode = 'ko'}) {
  AreaCode sido = getSiDoCodes(languageCode: languageCode).firstWhere(
    (address) => address.code == code,
  );
  return sido.name;
}