mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-09-01 11:13:26 +00:00
PROVIDER_CURRENCIES was permissive for everything except CBE_BILL, on the reasoning that the adapters pass input.currency through verbatim and nothing in them refuses a currency. That was the wrong place to look. The configuration says otherwise, and so does the domain: Telebirr is Ethio Telecom, CBE Birr is a Commercial Bank of Ethiopia wallet, and neither settles Djiboutian francs. The table as written would have let a DJF freight invoice be routed to one of them. payments.service.ts already states the rule above its chargeCurrency resolution — "WAAFI/DMONEY settle in DJF, CARD in USD, Ethiopian wallets in ETB" — and fix-payment-method-currency.ts corrected exactly WAAFI to DJF and CARD to USD, deliberately leaving the Ethiopian methods on the schema's ETB default. eBirr is configured as one of those: seeded region ETHIOPIA, never corrected. So TELEBIRR, CBE_BIRR, CBE_BILL and EBIRR are ETB-only. WAAFI, DMONEY and CAC_BANK stay open rather than pinned to DJF — that is their configured settlement currency, not a refusal of anything else, and passenger converts to each method's own currency before initiating regardless. CARD stays open too; its /100 minor-unit handling is a separate problem. Adds the spec that was missing: DJF must not reach a birr rail.