fix(pix): canonicalize +55 phone keys that already carry a + prefix#2240
Conversation
normalizePixPhoneNumber returned the raw input untouched when the cleaned value already started with '+', so '+55-11-99999-9999' kept its separators and stayed non-canonical — conflicting with the helper's contract and risking PIX-key mismatches. Always return the separator-free +55 form. From release-PR #2236 CodeRabbit triage; adds the separator-with-+ regression cases the existing +-prefix tests never exercised.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
Walkthrough
ChangesPIX Phone Number Normalization Fix
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
Comment |
Code-analysis diffPainscore total: 5798.03 → 5798.18 (+0.15) 🆕 New findings (3)
✅ Resolved (3)
|
🧪 UI test report — ✅ all greenSuites
📊 Coverage (unit)
⏱ 10 slowest test cases
|
From the release-PR (#2236) CodeRabbit triage.
normalizePixPhoneNumberreturned the raw input when the cleaned value already started with+, so+55-11-99999-9999kept its separators → non-canonical PIX key (risking key-match failures). Now always returns the separator-free+55form. Adds the separator-with-+regression cases (the existing+-prefix tests had no separators, so they never caught it). Non-phone inputs unchanged.