diff --git a/gnucash/report/report-system/html-table.scm b/gnucash/report/report-system/html-table.scm
index e1f9187bbb..771b2dab3f 100644
--- a/gnucash/report/report-system/html-table.scm
+++ b/gnucash/report/report-system/html-table.scm
@@ -139,15 +139,16 @@
(define (gnc:html-table-cell-render cell doc)
;; This function renders a html-table-cell to a document tree
- ;; segment. Note: if the html-table-cell datum is a negative number
- ;; or gnc:monetary, it fixes the tag eg. "number-cell" becomes
- ;; "number-cell-red". The number and gnc:monetary renderers do not
- ;; have an automatic -neg tag modifier. See bug 759005 and 797357.
+ ;; segment. Note: if the first element in a html-table-cell data is
+ ;; a negative number or gnc:monetary, it fixes the tag
+ ;; eg. "number-cell" becomes "number-cell-red". The number and
+ ;; gnc:monetary renderers do not have an automatic -neg tag
+ ;; modifier. See bug 759005 and bug 797357.
(let* ((retval '())
(push (lambda (l) (set! retval (cons l retval))))
(cell-tag (gnc:html-table-cell-tag cell))
(cell-data (gnc:html-table-cell-data cell))
- (tag (if (and (= 1 (length cell-data))
+ (tag (if (and (not (null? cell-data))
(not (string=? cell-tag "td"))
(or (and (gnc:gnc-monetary? (car cell-data))
(negative? (gnc:gnc-monetary-amount (car cell-data))))