propro-utils 1.5.37 → 1.5.38

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.
@@ -97,9 +97,6 @@ const checkIfUserExists = async accountId => {
97
97
  accountId
98
98
  );
99
99
  await user.save();
100
- user = await userSchema
101
- .findOne({ accountId })
102
- .populate('userGlobalStyles');
103
100
  }
104
101
  return user;
105
102
  }
@@ -116,7 +113,7 @@ const checkIfUserExists = async accountId => {
116
113
  userGlobalStyles: userGlobalStyles._id,
117
114
  });
118
115
 
119
- return await user.populate('userGlobalStyles');
116
+ return user;
120
117
  } catch (error) {
121
118
  console.error('Error in checkIfUserExists:', error);
122
119
  throw new Error('Failed to get or create user');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "propro-utils",
3
- "version": "1.5.37",
3
+ "version": "1.5.38",
4
4
  "description": "Auth middleware for propro-auth",
5
5
  "main": "src/index.js",
6
6
  "scripts": {