@rufous/aem 1.1.55 → 1.1.56

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.
@@ -15,7 +15,8 @@ exports.requireCompanyOrCandidateAuth = function (req, res, next) {
15
15
  && req.currentUser.uty != user_type_1.UserType.CompanyEmployee
16
16
  && req.currentUser.uty != user_type_1.UserType.CompanySuperuser
17
17
  && req.currentUser.uty != user_type_1.UserType.CompanyEmployeeManager
18
- && req.currentUser.uty != user_type_1.UserType.CompanyManager) {
18
+ && req.currentUser.uty != user_type_1.UserType.CompanyManager
19
+ && req.currentUser.uty != user_type_1.UserType.CompanyUser) {
19
20
  throw new not_authorized_error_1.NotAuthorizedError();
20
21
  }
21
22
  next();
@@ -15,7 +15,8 @@ exports.requirePartnerCandidateAuth = function (req, res, next) {
15
15
  && req.currentUser.uty != user_type_1.UserType.PartnerEmployeeManager
16
16
  && req.currentUser.uty != user_type_1.UserType.PartnerManager
17
17
  && req.currentUser.uty != user_type_1.UserType.Candidate
18
- && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser) {
18
+ && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser
19
+ && req.currentUser.uty != user_type_1.UserType.PartnerUser) {
19
20
  throw new not_authorized_error_1.NotAuthorizedError();
20
21
  }
21
22
  next();
@@ -16,7 +16,8 @@ exports.requirePartnerOrCandidateAuth = function (req, res, next) {
16
16
  && req.currentUser.uty != user_type_1.UserType.PartnerEmployee
17
17
  && req.currentUser.uty != user_type_1.UserType.PartnerEmployeeManager
18
18
  && req.currentUser.uty != user_type_1.UserType.PartnerManager
19
- && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser) {
19
+ && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser
20
+ && req.currentUser.uty != user_type_1.UserType.PartnerUser) {
20
21
  throw new not_authorized_error_1.NotAuthorizedError();
21
22
  }
22
23
  next();
@@ -16,7 +16,8 @@ exports.requireSuperAdminOrCompanyAuth = function (req, res, next) {
16
16
  && req.currentUser.uty != user_type_1.UserType.CompanyEmployee
17
17
  && req.currentUser.uty != user_type_1.UserType.CompanySuperuser
18
18
  && req.currentUser.uty != user_type_1.UserType.CompanyEmployeeManager
19
- && req.currentUser.uty != user_type_1.UserType.CompanyManager) {
19
+ && req.currentUser.uty != user_type_1.UserType.CompanyManager
20
+ && req.currentUser.uty != user_type_1.UserType.CompanyUser) {
20
21
  throw new not_authorized_error_1.NotAuthorizedError();
21
22
  }
22
23
  next();
@@ -17,7 +17,8 @@ exports.requireSuperAdminOrPartnerAuth = function (req, res, next) {
17
17
  && req.currentUser.uty != user_type_1.UserType.PartnerEmployee
18
18
  && req.currentUser.uty != user_type_1.UserType.PartnerEmployeeManager
19
19
  && req.currentUser.uty != user_type_1.UserType.PartnerManager
20
- && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser) {
20
+ && req.currentUser.uty != user_type_1.UserType.PartnerSuperuser
21
+ && req.currentUser.uty != user_type_1.UserType.PartnerUser) {
21
22
  throw new not_authorized_error_1.NotAuthorizedError();
22
23
  }
23
24
  next();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rufous/aem",
3
- "version": "1.1.55",
3
+ "version": "1.1.56",
4
4
  "main": "./build/index.js",
5
5
  "types": "./build/index.d.ts",
6
6
  "files": [