Docs: avoid plank comma in API reference
[blender.git] / doc / python_api / sphinx_doc_gen.py
index 1788b4cdcbc5acedef89a68ae355eb8cc03cb335..7f45335824a0c18e9dcfc5344a6b809a69c0520b 100644 (file)
@@ -1345,7 +1345,10 @@ def pyrna2sphinx(basepath):
                     descr = prop.description
                     if not descr:
                         descr = prop.name
-                    fw("         `%s`, %s, %s\n\n" % (prop.identifier, descr, type_descr))
+                    # In rare cases descr may be empty
+                    fw("         `%s`, %s\n\n" %
+                       (prop.identifier,
+                        ", ".join((val for val in (descr, type_descr) if val))))
 
             write_example_ref("      ", fw, "bpy.types." + struct_id + "." + func.identifier)