certValidityLabel function

String certValidityLabel(
  1. AppLocalizations l10n,
  2. Certification cert
)

How long a certificate stays valid once issued.

Uses an ICU plural rather than the entity's 'month${n == 1 ? '' : 's'}' suffix hack, which only produces correct English.

Implementation

String certValidityLabel(AppLocalizations l10n, Certification cert) =>
    cert.validityMonths != null
    ? l10n.orgCertValidityMonths(cert.validityMonths!)
    : l10n.orgCertNeverExpires;