Skip to content

Commit 085b374

Browse files
author
Martin Zihlmann
committed
allow custom extensions
1 parent 510bccf commit 085b374

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/apispec_webframeworks/flask.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ def path_helper(
150150
view = self._view_for_rule(rule, app=app)
151151
view_doc = view.__doc__ or ""
152152
doc_operations = yaml_utils.load_operations_from_docstring(view_doc)
153-
doc_operations = {k: v for k, v in doc_operations.items() if k.upper() in rule.methods}
153+
doc_operations = {k: v for k, v in doc_operations.items() if k.upper() in rule.methods or k.startswith("x-")}
154154
operations.update(doc_operations)
155155
if hasattr(view, "view_class") and issubclass(view.view_class, MethodView): # noqa: E501
156156
# method attribute is dynamically added, which is supported by mypy

0 commit comments

Comments
 (0)