292 | | if value[1]: |
293 | | return '%s<li>%s\n%s<ul>\n%s\n%s</ul>\n%s</li>' % (indent, value[0], indent, |
294 | | '\n'.join([_helper(v, tabs+1) for v in value[1]]), indent, indent) |
| 292 | if type(value) is type([]): |
| 293 | if value[1]: |
| 294 | if type(value[1]) is type([]): |
| 295 | return '%s<li>%s\n%s<ul>\n%s\n%s</ul>\n%s</li>' % (indent, value[0], indent, |
| 296 | '\n'.join([_helper(v, tabs+1) for v in value[1]]), indent, indent) |
| 297 | else: |
| 298 | return '\n'.join([_helper(v, tabs) for v in value]) |
| 299 | else: |
| 300 | return('%s<li>%s</li>' % (indent, value[0])) |