@riocrypto/common 1.0.469 → 1.0.471

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.
@@ -50,13 +50,10 @@ const authorize = (req, res, next, mongoose, authorizationTypes) => __awaiter(vo
50
50
  }
51
51
  }
52
52
  if (authorizationTypes.includes(authorization_type_1.AuthorizationType.Admin)) {
53
- console.log("ollie");
54
53
  if ((_f = req.cookies) === null || _f === void 0 ? void 0 : _f.adminJwt) {
55
54
  try {
56
55
  const payload = jsonwebtoken_1.default.verify(req.cookies.adminJwt, process.env.JWT_KEY_ADMIN);
57
- console.log("ollie2");
58
56
  req.currentAdminAuth = payload;
59
- console.log(req.currentAdminAuth);
60
57
  }
61
58
  catch (err) { }
62
59
  }
@@ -163,18 +160,14 @@ const authorize = (req, res, next, mongoose, authorizationTypes) => __awaiter(vo
163
160
  req.user = user;
164
161
  }
165
162
  }
166
- console.log(req);
167
163
  if (
168
164
  // if no auth
169
165
  (!req.currentAdminAuth && !req.currentAuth && !req.user && !req.partner) ||
170
166
  (!req.currentAuth &&
171
167
  !authorizationTypes.includes(authorization_type_1.AuthorizationType.Auth) &&
172
168
  !req.user)) {
173
- console.log("no auth");
174
- console.log(req.currentAuth);
175
169
  if (req.currentAdminAuth &&
176
170
  authorizationTypes.includes(authorization_type_1.AuthorizationType.Admin)) {
177
- console.log("skipping");
178
171
  next();
179
172
  return;
180
173
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common",
3
- "version": "1.0.469",
3
+ "version": "1.0.471",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",