for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Milwad\LaravelValidate\Rules;
use Illuminate\Contracts\Validation\Rule;
class ValidSlashEndOfString implements Rule
{
/**
* Check write slash at the end of string.
*/
public function passes($attribute, $value): bool
return preg_match('/\/+$/', $value);
return preg_match('/\/+$/', $value)
integer
boolean
}
* Get the validation error message.
public function message(): string
return __('validate.slash-end-of-string');