for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the Sylius package.
*
* (c) Paweł Jędrzejewski
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Sylius\Component\Resource\Exception;
/**
* @author Grzegorz Sadowski <[email protected]>
class UpdateHandlingException extends \Exception
{
* @var string
protected $flash;
* @var int
protected $apiResponseCode;
* @param string $message
* @param string $flash
* @param int $apiResponseCode
* @param int $code
* @param \Exception $previous
$previous
null|\Exception
This check looks for @param annotations where the type inferred by our type inference engine differs from the declared type.
@param
It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.
public function __construct(
$message = 'Ups, something went wrong, please try again.',
$flash = 'something_went_wrong_error',
$apiResponseCode = 400,
$code = 0,
\Exception $previous = null
) {
parent::__construct($message, $code, $previous);
$this->flash = $flash;
$this->apiResponseCode = $apiResponseCode;
}
* @return string
public function getFlash()
return $this->flash;
* @return int
public function getApiResponseCode()
return $this->apiResponseCode;
This check looks for
@paramannotations where the type inferred by our type inference engine differs from the declared type.It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.