fix(audit-log): add PAYMENT_RECONCILIATION_MISMATCH to categoryMap#965
Open
Whiznificent wants to merge 10 commits into
Open
fix(audit-log): add PAYMENT_RECONCILIATION_MISMATCH to categoryMap#965Whiznificent wants to merge 10 commits into
Whiznificent wants to merge 10 commits into
Conversation
- Add PAYMENT_RECONCILIATION_MISMATCH audit action - Create ReconciliationService to compare local payments with provider transactions - Create ReconciliationTask scheduled daily at 02:00 UTC - Add admin endpoint GET /payments/reconciliation/report - Update PaymentsModule and AppModule to include reconciliation components Closes rinafcode#856
- Add format check step (format:check) - Add unit tests step (test:ci) - Add E2E tests step (test:e2e) - Add PostgreSQL and Redis services for E2E tests - Configure environment variables for database and Redis connections
AuditAction.PAYMENT_RECONCILIATION_MISMATCH was added to the enum but was missing from the categoryMap in resolveCategoryForAction(), causing a TS2741 type error because the Record<AuditAction, AuditCategory> exhaustiveness check failed. Mapped to AuditCategory.COMPLIANCE to match related payment/compliance audit actions. Closes rinafcode#856
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #856 — TypeScript CI typecheck failure.
AuditAction.PAYMENT_RECONCILIATION_MISMATCHwas added to theAuditActionenum but was not added to thecategoryMapinsideresolveCategoryForAction()insensitive-operations.service.ts. Because the map is typed asRecord<AuditAction, AuditCategory>, TypeScript enforces exhaustiveness and fails withTS2741when any enum member is missing.Change
Added the missing entry to the
categoryMap:Mapped to
AuditCategory.COMPLIANCE— consistent with the other payment/financial audit actions in the compliance group (DATA_RETENTION_APPLIED,AUDIT_LOG_EXPORTED,REPORT_GENERATED).What was tested
Record<AuditAction, AuditCategory>constraint now has a value for every enum member.