From: Christian Heller Date: Sun, 27 Apr 2025 17:05:33 +0000 (+0200) Subject: Rather than remove them, turn into comment code-y lines from post-code gap fields... X-Git-Url: https://plomlompom.com/repos/%7B%7Bprefix%7D%7D/%22https:/validator.w3.org/todos?a=commitdiff_plain;h=398fedd50ce8fa6676b0ce4dd38bb1d1c571f1a0;p=ledgplom Rather than remove them, turn into comment code-y lines from post-code gap fields in edit pages. --- diff --git a/src/ledgplom/ledger.py b/src/ledgplom/ledger.py index 00db77d..dcf8b84 100644 --- a/src/ledgplom/ledger.py +++ b/src/ledgplom/ledger.py @@ -179,6 +179,8 @@ class _GapLine(_DatLineSubclass): @classmethod def from_dat(cls, dat_line: _DatLine) -> Self: + if dat_line.code: # if .code, turn whole line into comment + return cls('', dat_line.raw) return cls('', dat_line.comment)