Completed
Push — master ( ebed0b...7356ba )
by Jeremy
04:47
created

SoundRequest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 13
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A rules() 0 6 1
1
<?php
2
3
namespace App\Http\Requests;
4
5
use App\Http\Requests\SoundAdminRequest;
6
7
class SoundRequest extends SoundAdminRequest
8
{
9
    /**
10
     * Get the validation rules that apply to the request.
11
     *
12
     * @return array
13
     */
14
    public function rules()
15
    {
16
        return [
17
            'title'     => 'required|string|min:3|max:255|unique:sounds,title,'.$this->sound,
18
            'enabled'   => 'required|boolean',
19
            'file'      => 'required|string|min:12|max:255',
20
        ];
21
    }
22
}
23