Show deprecation notice for unbalanced entries

This commit is contained in:
Juerd Waalboer 2023-11-24 06:22:30 +01:00
parent ff819c25e2
commit 99154a4b62

View file

@ -241,9 +241,11 @@ sub sanity_check($self) {
@contras @contras
? "sum of entry with contras ($sum) != 0.00" ? "sum of entry with contras ($sum) != 0.00"
: "transaction has no contras" : "transaction has no contras"
) . ". This will probably be a fatal error in a future version of revbank.\n" ) . ". This will be a fatal error in a future version of revbank.\n"
. "The unbalanced entry is:\n" . join("\n", $self->as_printable) . "The unbalanced entry is:\n" . join("\n", $self->as_printable)
) );
warn "$self->{caller} has created an unbalanced entry, which is deprecated. Support for unbalanced entries will be removed in a future version of RevBank.\n";
} }
return 1; return 1;