nodebb-plugin-session-sharing 5.1.1 → 5.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/library.js +1 -0
  2. package/package.json +1 -1
package/library.js CHANGED
@@ -591,6 +591,7 @@ plugin.saveReverseToken = async ({ req, userData: data }) => {
591
591
 
592
592
  const res = req.res;
593
593
  const userData = await user.getUserFields(data.uid, ['uid', 'username', 'picture', 'reputation', 'postcount', 'banned']);
594
+ userData.groups = (await groups.getUserGroups([data.uid])).pop();
594
595
  const token = jwt.sign(userData, plugin.settings.secret);
595
596
 
596
597
  res.cookie('nbb_token', token, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodebb-plugin-session-sharing",
3
- "version": "5.1.1",
3
+ "version": "5.1.2",
4
4
  "description": "Allows login sessions from your app to persist in NodeBB",
5
5
  "main": "library.js",
6
6
  "repository": {