UNPKG

passport-zebedee-alpha

Version:

Zebedee (OAuth 2.0) authentication strategy for Passport.

19 lines (16 loc) 315 B
/** * Parse profile. * * Parses user profiles as fetched from Zebedee's API. * * @param {object|string} json * @return {object} * @access public */ exports.parse = function (json) { if (typeof json === 'string') { json = JSON.parse(json); } const { data: profile } = json; return profile; };