Skip to content

Commit

Permalink
Avoid printing marriage location twice
Browse files Browse the repository at this point in the history
  • Loading branch information
nigelhorne committed Jul 12, 2024
1 parent 239cee0 commit 7dc91ad
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion gedcom
Original file line number Diff line number Diff line change
Expand Up @@ -3926,7 +3926,21 @@ sub print_person
}
$phrase->append("[$marriagecitation]") if($marriagecitation);
if(defined($marriage)) {
append_notes({ phrase => $phrase, record => $marriage });
my $do_marriage_notes = 1;
if($placeofmarriage && (my $addr = $marriage->address()) && (my $notes = $marriage->get_value())) {
if("$addr, $placeofmarriage" =~ /^\Q$notes\E/) {
# This can happen with things like this
# 1 MARR Ebenezer Chapel, Meeting Street, Ramsgate
# 2 _PRIM Y
# 2 DATE 10 Dec 1882
# 2 PLAC Ramsgate, Kent, England
# 2 ADDR Ebenezer Chapel, Meeting Street
$do_marriage_notes = 0;
}
}
if($do_marriage_notes) {
append_notes({ phrase => $phrase, record => $marriage });
}
}
} else { # scalar(@spouses) > 1
if(is_alive(person => $person)) {
Expand Down

0 comments on commit 7dc91ad

Please sign in to comment.