title: Delete request in React with Axios
body: <p>I'm trying to make a delete request in React with Axios. My backend is node. I'm having trouble passing the data properly through axios. It sucessfully <a href="https://i.stack.imgur.com/elJAK.png" rel="nofollow noreferrer">console.log(res) </a>and hits the controller giving me the <code>Member sucessfully deleted</code> message. But when i refresh my page, the record is still there. I don't know what is causing that. 
  This is my axios code in react:</p>
  
  <pre><code>onDelete(memberId) {
      axios.delete('http://localhost:5000/api/members', {id: memberId})
          .then(res =&gt; {
              console.log(res)
              console.log('it works')
          })
          .catch(function (error) {
              console.log(error);
          });
  }
  </code></pre>
  
  <p>this is how i'm calling it: </p>
  
  <pre><code>&lt;Table.Body&gt;
      {this.state.members.map(member =&gt;
          &lt;Table.Row key={member._id}&gt;
              &lt;Table.Cell&gt;{member.name}&lt;/Table.Cell&gt;
              &lt;Table.Cell&gt;{member.email}&lt;/Table.Cell&gt;
              &lt;Table.Cell&gt; &lt;Button icon='remove user' onClick={() =&gt; this.onDelete(member._id)}/&gt;&lt;/Table.Cell&gt;
          &lt;/Table.Row&gt;
      )}
  &lt;/Table.Body&gt;
  </code></pre>
  
  <p>this is my controller: </p>
  
  <pre><code>exports.delete_a_member = function (req, res) {
      console.log(req.params);
      Member.remove({
          _id: req.params.memberId
      }, function (err, member) {
      if (err)
          res.send(err);
      res.json({message: 'Member successfully deleted!!'});
      });
  };
  </code></pre>
  
  <p>this is my route:</p>
  
  <pre><code>module.exports = function(app) {
      var members = require('../controllers/membersController');
  
      app.route('/api/members')
          .get(members.list_all_members)
          .post(members.create_a_member)
          .delete(members.delete_a_member);
  };
  </code></pre>