From aa63d7bf4bf38c7e6a3061218c322d684a15e2a5 Mon Sep 17 00:00:00 2001 From: haio Date: Mon, 28 Apr 2014 21:36:44 +0800 Subject: [PATCH] Convert principalId to String --- lib/models/acl.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/models/acl.js b/lib/models/acl.js index b14ebabc..3d2343d4 100644 --- a/lib/models/acl.js +++ b/lib/models/acl.js @@ -296,6 +296,7 @@ ACL.getStaticACLs = function getStaticACLs(model, property) { ACL.checkPermission = function checkPermission(principalType, principalId, model, property, accessType, callback) { + principalId = principalId.toString(); property = property || ACL.ALL; var propertyQuery = (property === ACL.ALL) ? undefined : {inq: [property, ACL.ALL]}; accessType = accessType || ACL.ALL;