Skip to content

Commit

Permalink
Fix spacing around unknown parents
Browse files Browse the repository at this point in the history
  • Loading branch information
nigelhorne committed Sep 23, 2024
1 parent 84ba4d6 commit 54ff620
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions gedcom
Original file line number Diff line number Diff line change
Expand Up @@ -3930,7 +3930,6 @@ sub print_person
$phrase->append(', un ' . lc($soccupation) . ',');
}
}
$phrase->append(' ');
}
my @childrenofthisspouse;
my $numberofchildrenwiththisspouse = $numberofchildren;
Expand Down Expand Up @@ -3975,6 +3974,7 @@ sub print_person
}
}
if(scalar(@childrenunknownparent) < $numberofchildren) {
$phrase->append(' ');
if($placeofmarriage || $dateofmarriage) {
if($language eq 'French') {
$phrase->append("avec qu'");
Expand Down Expand Up @@ -4569,7 +4569,9 @@ sub print_person
}

if(scalar(@childrenunknownparent)) {
push @phrases, $phrase;
if($phrase->length()) {
push @phrases, $phrase;
}
$bio->append(conjunction(map { $_->as_string() } @phrases))->append('. ');
$phrase = Data::Text->new("$pronoun ");
@phrases = ();
Expand Down Expand Up @@ -5958,11 +5960,11 @@ sub print_person
}
}
} else { # scalar(@residences) == 0
if($phrase->length()) {
push @phrases, $phrase;
$phrase = Data::Text->new();
}
if(scalar(@phrases)) {
if($phrase->length()) {
push @phrases, $phrase;
$phrase = Data::Text->new();
}
# No residences - remove any trailing commas
my $text = conjunction(map { $_->as_string() } @phrases);
$text =~ s/[\,;]\s*$//;
Expand Down

0 comments on commit 54ff620

Please sign in to comment.