mirror of
https://github.com/cryptpad/cryptpad.git
synced 2026-09-14 11:05:41 +05:00
Clean invalid classname and fix potential TypeError
This commit is contained in:
parent
d120f5ede1
commit
bb518e4ef5
@ -189,8 +189,7 @@ define([
|
||||
const table = h('table.cp-sidebar-table');
|
||||
if (header) {
|
||||
const headerValues = header.map(value => {
|
||||
const lastWord = value.split(' ').pop(); // Extracting the last word
|
||||
return h('th', { class: lastWord.toLowerCase() }, value); // Modified to use the last word
|
||||
return h('th', value);
|
||||
});
|
||||
const headerRow = h('thead', h('tr', headerValues));
|
||||
table.appendChild(headerRow);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user