Skip to content

Commit

Permalink
Trim name parts
Browse files Browse the repository at this point in the history
  • Loading branch information
c0shea committed Sep 30, 2017
1 parent 04a84a1 commit c57a5a6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions IdParser/IdentificationCard.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ private void ParseRecord(string subfileRecord)
// Required attributes
case "DAA":
var names = data.Split(',', '$');
LastName = names.Length > 0 ? names[0] : null;
FirstName = names.Length > 1 ? names[1] : null;
MiddleName = names.Length > 2 ? names[2] : null;
LastName = names.Length > 0 ? names[0].Trim() : null;
FirstName = names.Length > 1 ? names[1].Trim() : null;
MiddleName = names.Length > 2 ? names[2].Trim() : null;

break;

Expand Down

0 comments on commit c57a5a6

Please sign in to comment.