Socket
Socket
Sign inDemoInstall

nodebb-plugin-freelog

Package Overview
Dependencies
8
Maintainers
1
Versions
52
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.5 to 0.0.6

8

index.js

@@ -6,2 +6,4 @@ const plugin = {};

const userController = require.main.require('./src/controllers/user');
const User = module.parent.require('./user');
const nconf = module.parent.require('nconf');

@@ -40,2 +42,3 @@ // 签到处理

plugin.login = async function(req, username, password, next) {
console.log('secret', nconf.get('secret'));
if (!username) {

@@ -46,5 +49,8 @@ return next(new Error('[[error:invalid-username]]'));

console.log('登录成功');
userController.getUserDataByField(1, 'username', username, next);
const userData = await User.getUserData(1);
console.log(userData);
userController.getUserDataByField(1, 'username', username);
next(null, userData, '[[success:authentication-successful]]');
};
module.exports = plugin;

2

package.json

@@ -5,3 +5,3 @@ {

"description": "NodeBB Forum",
"version": "0.0.5",
"version": "0.0.6",
"homepage": "http://www.nodebb.org",

@@ -8,0 +8,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc