fix list formatting (#762)

This commit is contained in:
Darren Schroeder 2022-01-16 16:40:40 -06:00 committed by GitHub
parent 283a615ecc
commit c55b6c5ed5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -283,8 +283,10 @@ fn convert_to_table(
vec![("string".to_string(), (row_num + row_offset).to_string())];
if headers.is_empty() {
// if header row is empty, this is probably a list so format it that way
row.push(("list".to_string(), item.into_abbreviated_string(config)))
row.push((
item.get_type().to_string(),
item.into_abbreviated_string(config),
))
} else {
for header in headers.iter().skip(1) {
let result = match item {