Handle headerless tables
This commit is contained in:
parent
6b7123b1ad
commit
c116f6c1cb
2 changed files with 14 additions and 1 deletions
|
|
@ -22,6 +22,8 @@ impl Table {
|
|||
pub fn add_cell(&mut self, content: &str) {
|
||||
if let Some(last) = self.contents.last_mut() {
|
||||
last.push(content.trim().to_string());
|
||||
} else {
|
||||
self.contents.push(vec![content.trim().to_string()]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue