Rocket.Chat.ReactNative
Rocket.Chat.ReactNative copied to clipboard
fix: sanitize slugifyLikeString before slugifying
Proposed changes
Fix slugifyLikeString to properly sanitize strings before slugifying, preventing special characters from breaking functionality.
Issue(s)
No linked issue (or link the issue if one exists).
How to test or reproduce
Call slugifyLikeString with a string containing special or non-Latin characters, e.g., '測試123' → output should be 'ce-shi-123'.
Screenshots
Types of changes
Bugfix (non-breaking change which fixes an issue)
- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] Improvement (non-breaking change which improves a current function)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Documentation update (if none of the other choices apply)
Checklist
I have read the CONTRIBUTING doc
I have signed the CLA
Lint and unit tests pass locally with my changes
- [ ] I have read the CONTRIBUTING doc
- [ ] I have signed the CLA
- [ ] Lint and unit tests pass locally with my changes
- [ ] I have added tests that prove my fix is effective or that my feature works (if applicable)
- [ ] I have added necessary documentation (if applicable)
- [ ] Any dependent changes have been merged and published in downstream modules
Further comments
Summary by CodeRabbit
- Bug Fixes
- Improved input sanitization to ensure special characters are properly handled in text processing operations, enhancing data consistency and reliability.
✏️ Tip: You can customize this high-level summary in your review settings.