examples/express2/auth.js
function(consumerKey, done) {
    db.clients.findByConsumerKey(consumerKey, function(err, client) {
      if (err) { return done(err); }
      if (!client) { return done(null, false); }
      return done(null, client, client.consumerSecret);
    });
  }
function(consumerKey, done) {
    db.clients.findByConsumerKey(consumerKey, function(err, client) {
      if (err) { return done(err); }
      if (!client) { return done(null, false); }
      return done(null, client, client.consumerSecret);
    });
  }
function ( consumerKey , done ) { db . clients . findByConsumerKey ( consumerKey , function ( err , client ) { if ( err ) { return done ( err ) ; } if ( ! client ) { return done ( null , false ) ; } return done ( null , client , client . consumerSecret ) ; } ) ; }
consumer callback  This callback finds the registered client associated with `consumerKey`. The client should be supplied to the `done` callback as the second argument, and the consumer secret known by the server should be supplied as the third argument.  The `ConsumerStrategy` will use this secret to validate the request signature, failing authentication if it does not match.
consumer callback This callback finds the registered client associated with consumerKey . The client should be supplied to the done callback as the second argument and the consumer secret known by the server should be supplied as the third argument . The ConsumerStrategy will use this secret to validate the request signature failing authentication if it does not match .