has('is_replied')) { $this->merge([ 'is_replied' => filter_var($this->input('is_replied'), FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE), ]); } } /** * Determine if the user is authorized to make this request. */ public function authorize(): bool { return true; } /** * Get the validation rules that apply to the request. * * @return array|string> */ public function rules(): array { return [ 'publish_date_after' => ['nullable', 'date'], 'publish_date_before' => ['nullable', 'date', 'after_or_equal:publish_date_after'], 'rate_min' => ['nullable', 'integer', 'between:1,5'], 'rate_max' => ['nullable', 'integer', 'between:1,5'], 'app_version_code' => ['nullable', 'integer', 'min:1'], 'sdk_version' => ['nullable', 'integer', 'min:1'], 'is_replied' => ['nullable', 'boolean'], 'cursor' => ['nullable', 'string', 'max:2048'], ]; } }