gonameparts icon indicating copy to clipboard operation
gonameparts copied to clipboard

Names with comma are not always inverted

Open harlow opened this issue 8 years ago • 0 comments

Hi, nice library. I was running a few test cases... In general most are looking pretty good, however there is one issue I spotted:

name := gonameparts.Parse("John A. Smith, Jr.")
fmt.Printf("%s %s\n", name.FirstName, name.LastName)
#=> Jr. Smith

If there is a comma and its followed by any of the salutations then the name should not be flipped.

harlow avatar Dec 06 '16 16:12 harlow