Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

authentication

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

authentication - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

8

lib/http/request.js

@@ -51,3 +51,3 @@ /**

this._passport.session.user = user._id;
this._passport.session.usertype = user.type;
this._passport.session.type = user.type;
done();

@@ -74,2 +74,3 @@ } else {

delete this._passport.session.user;
delete this._passport.session.type;
}

@@ -84,3 +85,3 @@ };

*/
req.isAuthenticated = function () {
req.isAuthenticated = function (usertype) {
var property = 'user';

@@ -91,2 +92,5 @@ if (this._passport && this._passport.instance) {

if (this._passport && this._passport.session) {
var type= this._passport.session.type;
if(usertype != type)
return false;
return (this._passport.session.user) ? true : false;

@@ -93,0 +97,0 @@ }

{
"name": "authentication",
"version": "0.0.3",
"version": "0.0.4",
"description": "just like passport",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc