for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Mangopixel\Adjuster\Exceptions;
use Exception;
/**
* An exception which is thrown when trying to call save on a model that has applied
* adjustments through the applyAdjustments method on the CanBeAdjusted trait.
*
* @package Laravel Adjuster
* @author Alexander Tømmerås <[email protected]>
* @license The MIT License
*/
class ModelAdjustedException extends Exception
{
* Constructor.
* @param string $message
$message
null|string
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( string $message = null )
parent::__construct( $message ?: 'You cannot persist a model with applied adjustments and save protection enabled' );
}
This check looks for
@param
annotations 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.