Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

sails-permissions

Package Overview
Dependencies
Maintainers
1
Versions
83
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sails-permissions - npm Package Compare versions

Comparing version 0.10.11 to 0.10.12

25

api/hooks/permissions-api/index.js

@@ -1,3 +0,1 @@

var _ = require('lodash');
module.exports = function (sails) {

@@ -13,4 +11,2 @@ return {

},

@@ -36,3 +32,3 @@ initialize: function (next) {

})
.catch(function (error) {
.fail(function (error) {
sails.log.error(error);

@@ -68,7 +64,18 @@ next(error);

return require('../../../config/fixtures/user').create(roles, model, function (err, user) {
if (err) return next(err);
if (err) {
sails.log.error(err);
return next(err);
}
sails.log('admin user created. setting owner...');
user.owner = user.id;
user.save().then(function (user) {
next();
});
user.save()
.then(function (user) {
sails.log('admin user done. next...');
next();
})
.fail(function (error) {
sails.log('admin user fail');
sails.log.error(error);
next(error);
});
});

@@ -75,0 +82,0 @@ })

@@ -6,3 +6,2 @@ /**

exports.create = function (roles, model, next) {
sails.log('Installing admin User');

@@ -9,0 +8,0 @@ if (_.isEmpty(sails.config.permissions.adminPassword)) {

{
"name": "sails-permissions",
"version": "0.10.11",
"version": "0.10.12",
"description": "Comprehensive sails.js user permission/privilege framework that allows granting and restricting access to models and attributes based on object ownership and relationships with other users and roles",

@@ -41,4 +41,5 @@ "main": "index.js",

"pluralize": "^1.0.1",
"sails-auth": "^0.10.5",
"sails-generate-entities": "^0.10.3"
}
}
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