code: function hasPermission1(action) {
          var cacheItem = getCacheItem(permissionSchemaKey);
          var p = checkPermissionSync(action, userRoles, cacheItem);
          /*if (p.isAuthorized === false) {
           throw new PermissionError(null, req.session.user.userName, action);
           }*/
          return  p;
      }
docs: Returns validation result object
  This object has following keys:
  isAuthorized {Boolean}: whether action is authorized
  roleId {Number}: Role for which action is validated
  action {String}: Action for which permissions are checked
  
  @param action {String}
  @returns {Object}