<?php
namespace App\Http\Validators;

use Illuminate\Support\Facades\Validator;

class ForumValidator{

    public static function validate($data){
        $validator = Validator::make($data, [
            'title'         => 'required|max:190',
            'description'   => 'required',
            // 'images' => 'mimes:jpg,jpeg,png,gif,webp,bmp,mp4,mov,avi,mkv,flv,pdf,docx,doc'
        ]);

        if($validator->fails()){
            return array(
                'status' => false,
                'errors' => $validator->errors()
            );
        }

        return array(
            'status' => true
        );
    }
}
