Permalink
Browse files

fixed #11

  • Loading branch information...
1 parent 4d769bc commit c5753c840ef8bfa3e085b4b557041388cece8fe4 @manast manast committed Sep 1, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 lib/acl.js
  2. +1 −1 lib/memory-backend.js
View
@@ -674,7 +674,7 @@ Acl.prototype._checkPermissions = function(roles, resource, permissions, cb){
self.backend.union('parents', roles, function(err, parents){
if(err){
cb(err);
- } else if(parents.length){
+ } else if(parents && parents.length){
self._checkPermissions(parents, resource, permissions, cb);
}else{
cb(err, false);
View
@@ -75,7 +75,7 @@ MemoryBackend.prototype = {
}
cb(undefined, _.union(keyArrays));
}else{
- cb();
+ cb(undefined, []);
}
},

0 comments on commit c5753c8

Please sign in to comment.