LMongo\Eloquent\Relations\BelongsToMany::save PHP Method

save() public method

Save a new model and attach it to the parent model.
public save ( Model $model ) : Model
$model LMongo\Eloquent\Model
return LMongo\Eloquent\Model
    public function save(Model $model)
    {
        $model->save();
        $this->attach($model);
        return $model;
    }