Skip to content

Commit

Permalink
Merge pull request #6 from harryosmar/access-modif-attr-changes
Browse files Browse the repository at this point in the history
update class attribute access modifier
  • Loading branch information
harryosmar authored Jan 22, 2019
2 parents b543a07 + b02f1d9 commit ec814d2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class Response implements PhpRestfulApiResponse
*
* @var array
*/
private $phrases = [
protected $phrases = [
// INFORMATIONAL CODES
100 => 'Continue',
101 => 'Switching Protocols',
Expand Down Expand Up @@ -108,17 +108,17 @@ class Response implements PhpRestfulApiResponse
/**
* @var string
*/
private $reasonPhrase = '';
protected $reasonPhrase = '';

/**
* @var int
*/
private $statusCode;
protected $statusCode;

/**
* @var int|string
*/
private $errorCode;
protected $errorCode;

/**
* Response constructor.
Expand Down Expand Up @@ -407,7 +407,7 @@ public function setErrorCode($errorCode)
* @param int $statusCode
* @throws InvalidArgumentException on an invalid status code.
*/
private function setStatusCode(int $statusCode)
protected function setStatusCode(int $statusCode)
{
if ($statusCode < static::MIN_STATUS_CODE_VALUE
|| $statusCode > static::MAX_STATUS_CODE_VALUE
Expand All @@ -429,7 +429,7 @@ private function setStatusCode(int $statusCode)
* @return string
* @throws InvalidArgumentException if unable to encode the $data to JSON.
*/
private function jsonEncode($data)
protected function jsonEncode($data)
{
if (is_resource($data)) {
throw new InvalidArgumentException('Cannot JSON encode resources');
Expand Down

0 comments on commit ec814d2

Please sign in to comment.