oauthjs / node-oauth2-server

Complete, compliant and well tested module for implementing an OAuth2 Server/Provider with express in node.js
https://npmjs.org/package/oauth2-server
MIT License
4.02k stars 931 forks source link

Refresh token and Access token return different objects #165

Open Webdesignwill opened 9 years ago

Webdesignwill commented 9 years ago

Hey

Just a quick note. I've just got back to this from some time off so I might have missed something. I've updated to the version 2.4.0.

In my controller, when I find a user by the req.user.id object, if it's a refresh token I get a string with an id but if it's an access token, I get the entire object in a string.

Aren't they both meant to return the same object?

Thanks

thomseddon commented 9 years ago

Hmm, could you post your model to help debug?

Thanks