diff --git a/Modules/Media/Http/Requests/CreateFolderRequest.php b/Modules/Media/Http/Requests/CreateFolderRequest.php index 82e7b2916..8ae3557d7 100644 --- a/Modules/Media/Http/Requests/CreateFolderRequest.php +++ b/Modules/Media/Http/Requests/CreateFolderRequest.php @@ -4,6 +4,7 @@ use Illuminate\Foundation\Http\FormRequest; use Illuminate\Validation\Rule; +use Modules\Media\Validators\AlphaDashWithSpaces; class CreateFolderRequest extends FormRequest { @@ -13,7 +14,7 @@ public function rules() return [ 'name' => [ - 'alpha_dash', + new AlphaDashWithSpaces(), 'required', Rule::unique('media__files', 'filename')->where(function ($query) use ($parentId) { return $query->where('is_folder', 1)->where('folder_id', $parentId);