I am new to laravel and I am enjoying it. While working on a social media project I got this error: htmlspecialchars() expects parameter 1 to be string, object given (
I was getting this because in my view I was using $errors->get('username') to show errors but get() returns an array. Switching to $errors->first('username') fixed this.