Garden\Validation::mainMessage PHP Method

mainMessage() public method

Gets the main error message for the validation.
public mainMessage ( string | null $value = null ) : Validation | string
$value string | null Pass a new main message or null to get the current main message.
return Validation | string Returns the main message or $this for fluent sets.
    public function mainMessage($value = null)
    {
        if ($value !== null) {
            $this->mainMessage = $value;
            return $this;
        }
        return $this->mainMessage;
    }