title: LDAP JS auth getting error
body: <p>i am new to ldap. i am using ldapauth.js to authenticate the credentials. </p>
  
  <p>i have used ldapauth npm for authentucation.</p>
  
  <p>/*--------------LDAP_AUTH--------------*/</p>
  
  <pre><code>var ldap = require('ldapjs');
  var LdapAuth = require('ldapauth');
  var server = ldap.createServer();
  
  server.search('o=example', function(req, res, next) {
    var obj = {
      dn: req.dn.toString(),
      attributes: {
        objectclass: ['organization', 'top'],
        o: 'example'
      }
    };
  
    if (req.filter.matches(obj.attributes))
      res.send(obj);
  
    res.end();
  });
  
  server.listen(1389, function() {
    console.log('LDAP server listening at %s', server.url);
  });
  
  
  
  var options = {
      url: "ldap://0.0.0.0:1389",
      adminDn: "uid=myadminusername,ou=users,o=example",
      adminPassword: "mypassword",
      searchBase: "ou=users,o=example",
      searchFilter: "(uid={{username}})"
  };
  var auth = new LdapAuth(options);
  
  auth.authenticate('myadminusername', 'mypassword', function(err, user) { console.log('err'); 
      console.log(err);
  console.log(err.message);
  console.log('user');
  console.log(user);
  });
  
  auth.close(function(err) { console.log('errorr'); })
  </code></pre>
  
  <p>in the console i am getting the error message. </p>
  
  <pre><code>LDAP server listening at ldap://0.0.0.0:1389
  err
  { dn: [Getter],
    code: [Getter],
    name: [Getter],
    message: [Getter] }
  No tree found for: uid=myadminusername, ou=users, o=example
  user
  undefined
  </code></pre>
  
  <p>Please help me in figuring out what is wrong.</p>
  
  <p>Thanks for your time</p>