Download src/app/Http/Requests/Admin/WhatsappDeviceRequest.php from pnacorp/xsender: direct link, hf CLI and curl.
- Browser
- Download file 809 Bytes
-
https://huggingface.co/pnacorp/xsender/resolve/main/src/app/Http/Requests/Admin/WhatsappDeviceRequest.php
- Command line
-
hf download hf://pnacorp/xsender/src/app/Http/Requests/Admin/WhatsappDeviceRequest.php
-
curl -L -o WhatsappDeviceRequest.php https://huggingface.co/pnacorp/xsender/resolve/main/src/app/Http/Requests/Admin/WhatsappDeviceRequest.php
809 Bytes
| namespace App\Http\Requests\Admin; | |
| use App\Rules\DifferenceRule; | |
| use Illuminate\Foundation\Http\FormRequest; | |
| class WhatsappDeviceRequest extends FormRequest | |
| { | |
| /** | |
| * Determine if the user is authorized to make this request. | |
| * | |
| * @return bool | |
| */ | |
| public function authorize() | |
| { | |
| return true; | |
| } | |
| /** | |
| * Get the validation rules that apply to the request. | |
| * | |
| * @return array | |
| */ | |
| public function rules() | |
| { | |
| $rules = [ | |
| 'min_delay' => [ | |
| 'required', | |
| 'gte:10' | |
| ], | |
| 'max_delay' => [ | |
| 'required', | |
| 'gt:min_delay', | |
| new DifferenceRule(request()->input('min_delay')) | |
| ], | |
| ]; | |
| return $rules; | |
| } | |
| } | |