Skip to content

Commit

Permalink
tools,doc: fix incomplete json produced by doc tool
Browse files Browse the repository at this point in the history
Doc tool produces incomplete json when it meets unordered lists that
directly following a heading. Add a default case to processList function
to handle the lists.
  • Loading branch information
firedfox committed Apr 8, 2016
1 parent 7c9a691 commit 314d168
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tools/doc/json.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,14 @@ function processList(section) {
// event: each item is an argument.
section.params = values;
break;

default:
if (section.list.length > 0) {
section.desc = section.desc || [];
for (var i = 0; i < section.list.length; i++) {
section.desc.push(section.list[i]);
}
}
}

// section.listParsed = values;
Expand Down

0 comments on commit 314d168

Please sign in to comment.