title: Laravel Json Response Not working as expected
body: <p>Unable to get response while response object is empty. Works perfect when the object has data returned.</p>
  
  <pre><code>public function show($id)
  {
      $associates = Associate::find_by_id($id);
      if(count($associates)&lt;1)
      {
          $output = array('message' =&gt; 'No Records Found');
          $status = 204;
  
      }
      else{
          $output = array('message' =&gt; 'success','data'=&gt;$associates);
          $status = 200;
      }
      return response()-&gt;json($output,$status);
  }
  </code></pre>
  
  <p>There is no response when the $associate object is empty.
  Response when $associate is not empty:</p>
  
  <pre><code>{
  "message": "success",
  "data": [
      {
          "first_name": "xxx",
          "last_name": "xxx",
          "mobile": xxxxxxxxxx,
          "email": "xxxxxx@xxxxx",
          "city": "xxxxx",
          "state": "xxxxxx",
          "pincode": "xxxxx"
      }
    ]
  }
  </code></pre>