title: Nested relationships with Laravel faker - laravel seeder
body: <p>
  I wanted to make a post seeder with users and comments as mentioned in the relationship section in the laravel documentation <a href="https://laravel.com/docs/5.5/database-testing" rel="nofollow noreferrer">https://laravel.com/docs/5.5/database-testing</a> </p>
  
  
  
  <pre><code>  $users = factory(App\User::class, 3)
       -&gt;create()
       -&gt;each(function ($u) {
            $u-&gt;posts()-&gt;save(factory(App\Post::class)
              -&gt;create()
              -&gt;each(function($p){
                  $p-&gt;comments()-&gt;save(factory(App\Comment::class,5)
                    -&gt;create()
                    -&gt;each(function($c){
                        $c-&gt;user()-&gt;save(factory(App\User::class)
                          -&gt;make()
                        );
                    })
                  );
                })
              );
          }
      );
  </code></pre>
  
  <p>
  Expected output was to have 3 users having posts with 5 comments each.</p>
  
  <p>
  But error occurred:</p>
  
  <blockquote>
    <p>In Builder.php line 2459: Call to undefined method
    Illuminate\Database\Query\Builder::save()</p>
  </blockquote>