title: Adding new field to Laravel boilerplate user model
body: <p>I'm trying to add new field to laravel boiler user model. 
  in the fresh Laravel it have <code>App/User.php</code> where I can add field using $fillable . </p>
  
  <p>in the boilerplate it have <code>app/Models/Access/User/User.php</code> and it have 
  id as guarded <code>protected $guarded = ['id'];</code> . 
  also password, remember_token as $hidden <code>protected $hidden = ['password', 'remember_token'];</code>
  So everything else would be default fillable. </p>
  
  <p>But When I'm trying to add new field to user model , it's not adding to the database table. </p>
  
  <p>table already have field called <code>summery</code> . </p>
  
  <p>I've added summery field to the register.blade.php and tried to check if it's passing. </p>
  
  <p>added <code>return ($request);</code> to the <code>App\Service\Access\Trait\RegistersUsers.php</code></p>
  
  <pre><code> public function register(RegisterRequest $request)
  {
      if (config('access.users.confirm_email')) {
          $user = $this-&gt;user-&gt;create($request-&gt;all());
          event(new UserRegistered($user));
          dd ($request);
        //  return redirect()-&gt;route('frontend.index')-&gt;withFlashSuccess(trans('exceptions.frontend.auth.confirmation.created_confirm'));
      } else {
          auth()-&gt;login($this-&gt;user-&gt;create($request-&gt;all()));
          event(new UserRegistered(access()-&gt;user()));
          return redirect($this-&gt;redirectPath());
      }
  }
  </code></pre>
  
  <p>and it returns </p>
  
  <pre><code>POST /register HTTP/1.1 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8 Accept-Encoding: gzip, deflate Accept-Language: en-US,en;q=0.8 Cache-Control: max-age=0 Connection: keep-alive Content-Length: 170 Content-Type: application/x-www-form-urlencoded Cookie: XSRF-TOKEN={{removed}} Host: localhost:8000 Origin: http://localhost:8000 Referer: http://localhost:8000/ Upgrade-Insecure-Requests: 1 User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.94 Safari/537.36 _token=jwLZC59098AaUGFp4pYwv0m3sdEX91BhPvQn43Xq&amp;name=test+user&amp;password=testpass&amp;password_confirmation=testpass&amp;email=testmail%40test.com&amp;summery=test+summery&amp;terms=terms
  </code></pre>
  
  <p>but not table is not updated correctly . </p>
  
  <p>my other tables inputs and data retrieving well . only have problem with this model. </p>
  
  <p>please let me know if you need more information for helping me on this . </p>
  
  <p>Edit : </p>
  
  <p>Source of <code>app/Models/Access/User/User.php</code></p>
  
  <pre><code>&lt;?php
  
  namespace App\Models\Access\User;
  
  use App\Models\Access\User\Traits\UserAccess;
  use Illuminate\Database\Eloquent\SoftDeletes;
  use Illuminate\Foundation\Auth\User as Authenticatable;
  use App\Models\Access\User\Traits\Attribute\UserAttribute;
  use App\Models\Access\User\Traits\Relationship\UserRelationship;
  
  /**
   * Class User
   * @package App\Models\Access\User
   */
  class User extends Authenticatable
  {
  
      use SoftDeletes, UserAccess, UserAttribute, UserRelationship;
  
  
  
      /**
       * The attributes that are not mass assignable.
       *
       * @var array
       */
      protected $guarded = ['id'];
  
      /**
       * The attributes that should be hidden for arrays.
       *
       * @var array
       */
      protected $hidden = ['password', 'remember_token'];
  
      /**
       * @var array
       */
      protected $dates = ['deleted_at'];
  }
  </code></pre>
  
  <p>edit2 : dd ($request); </p>
  
  <pre><code>RegisterRequest {#430 ▼
    #container: Application {#3 ▶}
    #redirector: Redirector {#437 ▶}
    #redirect: null
    #redirectRoute: null
    #redirectAction: null
    #errorBag: "default"
    #dontFlash: array:2 [▼
      0 =&gt; "password"
      1 =&gt; "password_confirmation"
    ]
    #json: null
    #convertedFiles: []
    #userResolver: Closure {#356 ▶}
    #routeResolver: Closure {#355 ▶}
    +attributes: ParameterBag {#432 ▶}
    +request: ParameterBag {#429 ▶}
    +query: ParameterBag {#431 ▶}
    +server: ServerBag {#435 ▶}
    +files: FileBag {#434 ▶}
    +cookies: ParameterBag {#433 ▶}
    +headers: HeaderBag {#436 ▶}
    #content: "_token=Md4aX1QOSbxjDhLWQStyrKWMW25oKiD1mWU9xhgE&amp;name=Test+User+two&amp;password=testpass&amp;password_confirmation=testpass&amp;email=test%40test.com&amp;summery=test+summery&amp;terms=terms"
    #languages: null
    #charsets: null
    #encodings: null
    #acceptableContentTypes: null
    #pathInfo: null
    #requestUri: null
    #baseUrl: null
    #basePath: null
    #method: "POST"
    #format: null
    #session: Store {#386 ▶}
    #locale: null
    #defaultLocale: "en"
  }
  </code></pre>
  
  <p>Edit 3 : source from <code>App\Events\Auth\UserRegistered.php</code></p>
  
  <pre><code>&lt;?php
  
  namespace App\Events\Frontend\Auth;
  
  use App\Events\Event;
  use Illuminate\Queue\SerializesModels;
  
  /**
   * Class UserRegistered
   * @package App\Events\Frontend\Auth
   */
  class UserRegistered extends Event
  {
      use SerializesModels;
  
      /**
       * @var $user
       */
      public $user;
  
      /**
       * @param $user
       */
      public function __construct($user)
      {
          $this-&gt;user = $user;
      }
  }
  </code></pre>