You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Low — consistency / cleanup, no active user-facing bug.
Findings
Triple country representation. The same country datum is serialized three different ways: registration top-level fields use the 2-letter symbol string; the standalone nationality step, kycData.address.country, and the settings address edit use the numeric id; RealUnitUserDataDto from the backend returns the symbol string (resolved app-side via getCountryBySymbol). There is no central serialization layer — each service method picks its own representation.
addressCountry serialized twice in the registration request. It is sent once as a symbol string top-level and once as {id} inside kycData.address.country (lib/packages/service/dfx/real_unit_registration_service.dart); the kycData copy is not covered by the EIP-712 signature.
Country.foreignName is dead. Loaded from the DTO and mapped onto Country, but never read anywhere in lib/. Either use it (e.g. localized display) or drop it.
lang hardcoded to 'DE' in the registration request (real_unit_registration_service.dart), despite a localized app and an existing DfxLanguageService. An English-speaking user is registered with lang='DE'.
Severity
Low — consistency / cleanup, no active user-facing bug.
Findings
kycData.address.country, and the settings address edit use the numericid;RealUnitUserDataDtofrom the backend returns the symbol string (resolved app-side viagetCountryBySymbol). There is no central serialization layer — each service method picks its own representation.addressCountryserialized twice in the registration request. It is sent once as a symbol string top-level and once as{id}insidekycData.address.country(lib/packages/service/dfx/real_unit_registration_service.dart); thekycDatacopy is not covered by the EIP-712 signature.Country.foreignNameis dead. Loaded from the DTO and mapped ontoCountry, but never read anywhere inlib/. Either use it (e.g. localized display) or drop it.langhardcoded to'DE'in the registration request (real_unit_registration_service.dart), despite a localized app and an existingDfxLanguageService. An English-speaking user is registered withlang='DE'.displayOrderis loaded but never used.CountryFieldrelies on the backend already sorting/v1/country; there is no local sort fallback. Note: the backend has nodisplayOrdercolumn at all (see CountryDto: nationalityAllowed maps to an unused column; no DTO field exposes the real nationality gate DFXswiss/api#3755), so the field is effectively always its default — either sort locally or drop the field.Countryequality isid-only (props => [id]). Fragile if twoCountryinstances share anidbut differ in other fields.Context
Found during a deep audit of the KYC country/nationality data path (see #519). Backend-side counterparts: DFXswiss/api#3754, DFXswiss/api#3755.