You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yeah it's a little ridiculous that this isn't documented, given that checking it is pretty much the entire ultimate goal of this library...
The consequence of this little mistake is a zillion tutorials that stop at the page authorization part, or goofie strategies like checking if random session fields are undefined.
It's sort of beyond me how Passport has gone on for so long with zero mention of this function on the page, in the readme, or in any other docs, given how important it is.
Apparently Passport adds isAuthenticated (and isUnauthenticated) to the Request object, as mentioned in this SO post: http://stackoverflow.com/questions/14188834/documentation-for-ensureauthentication-isauthenticated-passports-functions/14301657#14301657
Is there any reason why this isn't documented?
The text was updated successfully, but these errors were encountered: