merge([ 'published' => $this->boolean('published') ]); } /** * Get the validation rules that apply to the request. * * @return array */ public function rules(): array { return [ 'label' => 'required|string|between:3,255', 'published' => 'required|boolean', ]; } /** * Get custom attributes for validator errors. * * @return array */ public function attributes(): array { return [ 'label' => trans('validation.custom.label'), 'published' => trans('validation.attributes.published') ]; } }