mirror of
https://github.com/retailcrm/NelmioApiDocBundle.git
synced 2025-02-02 23:59:26 +03:00
Remove @ApiDoc::$parsedResponseMap
This commit is contained in:
parent
9b677f2ff3
commit
1e8692ad37
@ -97,11 +97,6 @@ class ApiDoc
|
|||||||
*/
|
*/
|
||||||
private $responseMap = array();
|
private $responseMap = array();
|
||||||
|
|
||||||
/**
|
|
||||||
* @var array
|
|
||||||
*/
|
|
||||||
private $parsedResponseMap = array();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
@ -459,10 +454,6 @@ class ApiDoc
|
|||||||
$data['response'] = $response;
|
$data['response'] = $response;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($parsedResponseMap = $this->parsedResponseMap) {
|
|
||||||
$data['parsedResponseMap'] = $parsedResponseMap;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($statusCodes = $this->statusCodes) {
|
if ($statusCodes = $this->statusCodes) {
|
||||||
$data['statusCodes'] = $statusCodes;
|
$data['statusCodes'] = $statusCodes;
|
||||||
}
|
}
|
||||||
@ -489,25 +480,4 @@ class ApiDoc
|
|||||||
|
|
||||||
return $this->responseMap;
|
return $this->responseMap;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getParsedResponseMap()
|
|
||||||
{
|
|
||||||
return $this->parsedResponseMap;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param $model
|
|
||||||
* @param $type
|
|
||||||
* @param int $statusCode
|
|
||||||
*/
|
|
||||||
public function setResponseForStatusCode($model, $type, $statusCode = 200)
|
|
||||||
{
|
|
||||||
$this->parsedResponseMap[$statusCode] = array('type' => $type, 'model' => $model);
|
|
||||||
if ($statusCode == 200 && $this->response !== $model) {
|
|
||||||
$this->response = $model;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user