src/Concerns/HasAttributes.php
public function addMissingAttributes()
    {
        foreach ($this->getSchema() as $key => $settings) {
            if (!array_has($this->attributes, $key)) {
                array_set($this->attributes, $key, array_get($settings, 'default', null));
            }
        }
    }
public function addMissingAttributes()
    {
        foreach ($this->getSchema() as $key => $settings) {
            if (!array_has($this->attributes, $key)) {
                array_set($this->attributes, $key, array_get($settings, 'default', null));
            }
        }
    }
public function addMissingAttributes ( ) { foreach ( $ this -> getSchema ( ) as $ key => $ settings ) { if ( ! array_has ( $ this -> attributes , $ key ) ) { array_set ( $ this -> attributes , $ key , array_get ( $ settings , 'default' , null ) ) ; } } }
Set's mising attributes.

This covers situations where values have defaults but are not fillable, or
date field.

@return void
Set s mising attributes .