Encode any 3 character ASCII currency code (#106)

* Encode all 3 character ASCII codes
This commit is contained in:
Nathan Nichols
2020-09-14 13:09:38 -05:00
parent a5559825ae
commit b197897227
5 changed files with 26 additions and 2 deletions

View File

@@ -18,7 +18,7 @@ function isoToBytes(iso: string): Buffer {
* Tests if ISO is a valid iso code
*/
function isIsoCode(iso: string): boolean {
return ISO_REGEX.test(iso);
return iso.length === 3;
}
/**