title: How to use laravel pagination with filter
body: <p>I have <code>getCanSeeAttribute</code> function in post model, and I try to get posts with pagination using <code>filter()</code> </p>
  
  <pre><code>$posts = Post::where(function ($query1) use ($users) {
              $query1-&gt;where('posted_type', 'user')-&gt;whereIn('posted_id', $users);
          })
          -&gt;orWhere(function ($query2) use ($stores) {
              $query2-&gt;where('posted_type', 'store')-&gt;whereIn('posted_id', $stores);
          })
          -&gt;with('likes', 'postable')
          -&gt;withCount('comments', 'likes')
          -&gt;latest()-&gt;paginate($paginate)-&gt;filter(function($post){
              return $post-&gt;can_see == true;
          });
  </code></pre>
  
  <p>The problem is when I use filter, it gets data attribute only, but I need all pagination attributes. </p>
  
  <pre><code>first_page_url": "http://localhost:8000/api/timeline?page=1",
  "from": 1,
  "last_page": 1,
  "last_page_url": "http://localhost:8000/api/timeline?page=1",
  "next_page_url": null,
  "path": "http://localhost:8000/api/timeline",
  "per_page": 10,
  "prev_page_url": null,
  "to": 6,
  "total": 6
  </code></pre>
  
  <p><strong>can_see not column in table it is Accessor</strong></p>