-
Notifications
You must be signed in to change notification settings - Fork 16
Normalize names that are all uppercased #3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
Jon - thanks for contributing back! This design is on purpose so we do not normalize the LLC, LLP, LP and other similar acronyms for other countries. If I merge your patch these will be normalized as Llc and Llp, which is incorrect. The solution might be to set a flag after line 125 and add a test for this flag on line 132. |
|
Thanks for the test case. Agreed that this is important, and hopefully we also agree that handling the all-uppercase scenario is important. I'll submit a new PR that handles both shortly. |
|
Another thing that I am not sure how to address with this use case is orgs that have all caps for their names. -Steve |
|
Good point Steve. Do you have any names that pop in mind? ------ Original Message ------
|
|
Not Civi users but DRCOG, DRMAC - they have full names but they might On Fri, Aug 21, 2015 at 1:41 PM, nganivet notifications@github.com wrote:
Steve Kessler |
|
Can we just handle all-uppercased first/last names, and not organization names? Folks with all-capital names are still an issue, but hopefully are enough of an edge case? It also seems like of most folks with all-capital names, the most common case is someone whose first name is initials (e.g. "JT Smith"), so we can also not do title case on names with a length < 3. |
|
OK, sounds reasonable. Can you document this with a comment in the code? ------ Original Message ------
|
|
OK, I fixed this PR! |
|
Jon - sorry this is not merged yet. I have doubts as to whether this one line fix does not have other side effects, and almost all my customers have this extension installed so I need to exercise extra caution. Can you please confirm that you have this modification in production with some of your customers and that it resolves all the use cases described above with no other side effects? Thanks. |
|
Hi Nicolas - no worries! I do have a client using this in production - the only one who uses this extension. There aren't any side effects, though note that it doesn't handle the situation I mentioned above ("JT Smith"). |
The current normalization code seems geared toward names entered as all lowercase - but doesn't handle the situation of a name entered in all uppercase. This PR addresses the all uppercase situation.