Fix bug in HTML table generation

Introduced in 73fdc39d77e41e4f358534c882607b16672fc319