title: Distinct node js MongoDB case insensitive
body: <p>I am using distinct in Mongo to return some values in the Jquery Autocomplete like this:</p>
  
  <pre><code>function Reg(title)
      {
          this.title= title;
      }
  
  exports.find = function(req, res) {
  var b=req.params.search;
  var query = new Array();
  var cadsrch = b.split(' ');
  var l = cadsrch.length;
  var i = 0;
          for (i = 0; i &lt; l; i++) {
              if(cadsrch[i]!=''){
                query[i]=new RegExp('^'+cadsrch[i], 'i');
              }
          }
  
  var data=new Array();
          db.collection('publication', function(err, collection) {
                  collection.distinct('title',{content:{'$all':query}},{'$or':[{type:'an'},{type:'pub'}]},
                    function(err, items) {
                           var l=items.length,i=0;
                           for (i=0;i&lt;l;i++){
                              data[i]=new Reg(items[i]);
                           }
                           res.jsonp(data);
                           }
                  )
          });
  };
  </code></pre>
  
  <p>The problem is that the columns 'title' is working in case sensitive, I mean for example car is different to Car, I don't know if there is a way to avoid this and take Car the same as car </p>