|
|
|
|
@ -28,7 +28,6 @@ use OCP\AppFramework\Http; |
|
|
|
|
use OCP\AppFramework\OCSController; |
|
|
|
|
|
|
|
|
|
class V1Response extends BaseResponse { |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* The V1 endpoint has very limited http status codes basically everything |
|
|
|
|
* is status 200 except 401 |
|
|
|
|
@ -68,7 +67,7 @@ class V1Response extends BaseResponse { |
|
|
|
|
public function render() { |
|
|
|
|
$meta = [ |
|
|
|
|
'status' => $this->getOCSStatus() === 100 ? 'ok' : 'failure', |
|
|
|
|
'statuscode' => (string)$this->getOCSStatus(), |
|
|
|
|
'statuscode' => $this->getOCSStatus(), |
|
|
|
|
'message' => $this->getOCSStatus() === 100 ? 'OK' : $this->statusMessage ?? '', |
|
|
|
|
'totalitems' => (string)($this->itemsCount ?? ''), |
|
|
|
|
'itemsperpage' => (string)($this->itemsPerPage ?? ''), |
|
|
|
|
|