summaryrefslogtreecommitdiff
path: root/rest-api-templates/asterisk_processor.py
diff options
context:
space:
mode:
authorMatt Jordan <mjordan@digium.com>2015-10-20 22:24:36 -0500
committerMatt Jordan <mjordan@digium.com>2015-10-20 22:41:55 -0500
commitb425850f8b859a04c997d71eced223a445097c4e (patch)
tree43f7fb74298594df1b12ae68dd636ac2ca81aa2a /rest-api-templates/asterisk_processor.py
parentb19860c03a1656fbf6409daf99b5fc98101e7134 (diff)
rest-api-templates: Wikify error code response reasons
Error response code descriptions may contain wiki markup that need to be escaped. Without this patch, Confluence will reject the document being sent and the responsible script will raise an exception. Change-Id: I21fcb66fee7f6332381f2b99b1b0195dff215ee5
Diffstat (limited to 'rest-api-templates/asterisk_processor.py')
-rw-r--r--rest-api-templates/asterisk_processor.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/rest-api-templates/asterisk_processor.py b/rest-api-templates/asterisk_processor.py
index ab8a8afd2..68a679994 100644
--- a/rest-api-templates/asterisk_processor.py
+++ b/rest-api-templates/asterisk_processor.py
@@ -199,6 +199,8 @@ class AsteriskProcessor(SwaggerPostProcessor):
raise SwaggerError("Summary should end with .", context)
operation.wiki_summary = wikify(operation.summary or "")
operation.wiki_notes = wikify(operation.notes or "")
+ for error_response in operation.error_responses:
+ error_response.wiki_reason = wikify(error_response.reason or "")
operation.parse_body = (operation.body_parameter or operation.has_query_parameters) and True
def process_parameter(self, parameter, context):