Fix API response code mismatch

Response mismatch between http reponse and json payload for configdocs replace

Change-Id: I979cd31e26660149d0121d65298d106afbb24008
This commit is contained in:
hs571j 2018-06-27 11:43:29 -05:00 committed by hosingh000
parent 58e2949cdc
commit 8b43d75ecf
1 changed files with 3 additions and 1 deletions

View File

@ -86,9 +86,11 @@ class ConfigDocsResource(BaseResource):
document_data=document_data,
buffer_mode_param=buffer_mode)
resp.status = falcon.HTTP_201
if validations and validations['status'] == 'Success':
validations['code'] = resp.status
resp.location = '/api/v1.0/configdocs/{}'.format(collection_id)
resp.body = self.to_json(validations)
resp.status = falcon.HTTP_201
@policy.ApiEnforcer('workflow_orchestrator:get_configdocs')
def on_get(self, req, resp, collection_id):