Prevent panic when assembling the import details
This commit is contained in:
parent
c389dec868
commit
f1b8bc79e2
|
@ -119,7 +119,7 @@ func decomposeDocstring(docstring string) docInfo {
|
|||
description := schema.RenderDocsToString(source, parsed)
|
||||
importDetails := ""
|
||||
parts := strings.Split(description, "\n\n## Import")
|
||||
if len(parts) > 0 {
|
||||
if len(parts) > 1 { // we only care about the Import section details here!!
|
||||
importDetails = parts[1]
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue