var Strategy = require('passport-twitter').Strategy; const User = require("../../models/user"); const twitter = new Strategy({ consumerKey: process.env['TWITTER_CONSUMER_KEY'], consumerSecret: process.env['TWITTER_CONSUMER_SECRET'], callbackURL: '/oauth/callback' }, function(token, tokenSecret, profile, cb) { // In this example, the user's Twitter profile is supplied as the user // record. In a production-quality application, the Twitter profile should // be associated with a user record in the application's database, which // allows for account linking and authentication with other identity // providers. return cb(null, profile); }) module.exports = local;