Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
3 / 3
100.00% covered (success)
100.00%
2 / 2
CRAP
100.00% covered (success)
100.00%
1 / 1
FlyShareResetInShortcutRequest
100.00% covered (success)
100.00%
3 / 3
100.00% covered (success)
100.00%
2 / 2
2
100.00% covered (success)
100.00%
1 / 1
 authorize
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 rules
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3namespace App\Http\Requests;
4
5use App\Http\Models\Shortcut;
6use Illuminate\Foundation\Http\FormRequest;
7
8class FlyShareResetInShortcutRequest extends FormRequest
9{
10    /**
11     * Determine if the user is authorized to make this request.
12     */
13    public function authorize(): bool
14    {
15        return Shortcut::where('reference_shares_shortcut_id', $this->sharesShortcut->_id)->exists();
16    }
17
18    /**
19     * Get the validation rules that apply to the request.
20     */
21    public function rules(): array
22    {
23        return [
24        ];
25    }
26}