I have a laravel User model which has a unique validation rule on username and email. In my Repository, when I update the model, I rev
User
username
email
You can trying code bellow
return [ 'email' => 'required|email|max:255|unique:users,email,' .$this->get('id'), 'username' => 'required|alpha_dash|max:50|unique:users,username,'.$this->get('id'), 'password' => 'required|min:6', 'confirm-password' => 'required|same:password', ];