In my AppServideProvider's boot method I've set a custom validation rule for cyrillic. Here is what it lookes like:
public function boot()
{
Validator::extend('cyrillic', function ($attribute, $value, $parameters, $validator) {
return preg_match('/[А-Яа-яЁё]/u', $value);
});
}
It works as expected. However if the validation doesn't pass because of latin input I get the error message 'validation.cyrillic'. How can I fix that? How can I pass a custom message to my 'cyrillic' validation rule?