diff --git a/openflexure_microscope/common/flask_labthings/views/docs/__init__.py b/openflexure_microscope/common/flask_labthings/views/docs/__init__.py index 9fbf4e25..f154018d 100644 --- a/openflexure_microscope/common/flask_labthings/views/docs/__init__.py +++ b/openflexure_microscope/common/flask_labthings/views/docs/__init__.py @@ -48,7 +48,9 @@ class W3CThingDescriptionResource(Resource): for key, prop in current_labthing().actions.items(): actions[key] = {} actions[key]["title"] = prop.__name__ - actions[key]["description"] = get_docstring(prop) + actions[key]["description"] = get_docstring(prop) or ( + get_docstring(prop.post) if hasattr(prop, "post") else "" + ) actions[key]["links"] = [ {"href": current_labthing().url_for(prop, _external=True)} ]