New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ee-soa-service

Package Overview
Dependencies
Maintainers
2
Versions
176
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ee-soa-service - npm Package Compare versions

Comparing version 0.2.29 to 0.2.30

18

lib/DefaultService.js

@@ -25,16 +25,4 @@

, _permissionMap: {
list: 'read'
, listOne: 'read'
, create: 'create'
, createOrUpdate: 'create'
, update: 'update'
, updateRelation: 'update'
, delete: 'delete'
, deleteRelation: 'delete'
, describe: 'describe'
}
, init: function(options, dirname) {

@@ -227,3 +215,3 @@ this.options = options || {};

// check permissions, go through or return an error
if (permission.isActionAllowed(this.name+'.'+collection, this._permissionMap[action] || action)) {
if (permission.isActionAllowed(this.name+'.'+collection, action)) {

@@ -241,3 +229,3 @@ if (debugService) log.info('[DefaultService] '+[this.name, req.getCollection(), req.getActionName()].join('.')+' - access was granted!');

callback(new Error('You [the user(s) '+permission.getUsers().map(function(u) {return u.id}).join(', ')+' and the service(s) '+permission.getServices().map(function(s) {return s.identifier}).join(', ')+'] are not allowed to access the controller «'+collection+'», action «'+(this._permissionMap[action] || action)+'» on the service «'+this.name+'»!'), {}, SOAResponse.statusCodes.ACCESS_UNAUTHORIZED);
callback(new Error('You [the user(s) '+permission.getUsers().map(function(u) {return u.id}).join(', ')+' and the service(s) '+permission.getServices().map(function(s) {return s.identifier}).join(', ')+'] are not allowed to access the controller «'+collection+'», action «'+(action)+'» on the service «'+this.name+'»!'), {}, SOAResponse.statusCodes.ACCESS_UNAUTHORIZED);
}

@@ -248,3 +236,3 @@ }.bind(this)).catch(function(err) {

// failed to load the permissions
callback(new Error('Failed to load the permissions for the controller «'+collection+'», action «'+(this._permissionMap[action] || action)+'» on the service «'+this.name+'»: '+err), {}, SOAResponse.statusCodes.SERVICE_EXCEPTION);
callback(new Error('Failed to load the permissions for the controller «'+collection+'», action «'+(action)+'» on the service «'+this.name+'»: '+err), {}, SOAResponse.statusCodes.SERVICE_EXCEPTION);
}.bind(this));

@@ -251,0 +239,0 @@ }

2

package.json

@@ -5,3 +5,3 @@ {

, "keywords" : ["ee", "soa", "service"]
, "version" : "0.2.29"
, "version" : "0.2.30"
, "author": {

@@ -8,0 +8,0 @@ "name" : "Tobias Kneubuehler"

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc