title: Laravel error: Call to a member function format() on string
body: <p>I am using Laravel <code>5.3</code>.   </p>
  
  <p>There is a  field <code>expired_at</code>  in  table <code>articles</code>：</p>
  
  <pre><code>public function store(Request $request)
  {
      $data=[
           'expired_at'=&gt;Carbon::now()-&gt;addDays(30)-&gt;endOfDay()
      ];
      $article=Article::create(array_merge($request-&gt;all(),$data));
  
      return redirect('/artilces');
  }
  </code></pre>
  
  <p>view:</p>
  
  <pre><code>{{$article-&gt;expired_at-&gt;format('Y-m-d')}}
  </code></pre>
  
  <p>error:</p>
  
  <blockquote>
    <p>Call to a member function format() on string (View: D:\wnmp\www\laravel-5-3-dev\resources\views\artiles\index.blade.php)</p>
  </blockquote>
  
  <p>Why is it？</p>