diff --git a/Models/Unit.ts b/Models/Unit.ts index 90661ecc9..e6ab43a4e 100644 --- a/Models/Unit.ts +++ b/Models/Unit.ts @@ -116,7 +116,9 @@ export class Unit { (u, i) => new Denomination( u, - u.canonicalDenomination.trim() === json.defaultInput, + u.canonicalDenomination === undefined + ? undefined + : u.canonicalDenomination.trim() === json.defaultInput, `${ctx}.units[${i}]` ) )