src/Concerns/HasAttributes.php
public function savingValidation()
    {
        global $app;

        $this->preValidationCast();
        $this->validator = new Validator($app['translator'], $this->getDirty(), $this->getAttributeRules());

        if ($this->validator->fails()) {
            return false;
        }

        return true;
    }
public function savingValidation()
    {
        global $app;

        $this->preValidationCast();
        $this->validator = new Validator($app['translator'], $this->getDirty(), $this->getAttributeRules());

        if ($this->validator->fails()) {
            return false;
        }

        return true;
    }
public function savingValidation ( ) { global $ app ; $ this -> preValidationCast ( ) ; $ this -> validator = new Validator ( $ app [ 'translator' ] , $ this -> getDirty ( ) , $ this -> getAttributeRules ( ) ) ; if ( $ this -> validator -> fails ( ) ) { return false ; } return true ; }
Validate the model before saving.

@return array
Validate the model before saving .