From d41a22496ab2aeee2953a8e2b9f6c70275787b76 Mon Sep 17 00:00:00 2001 From: Arne Hassel Date: Wed, 28 Aug 2019 14:00:01 +0200 Subject: [PATCH] Allow for creation of ACL resources on folders directly under root This fixes https://github.com/solid/solid-ui/issues/99 The test was there to prohibit calls on https://, as we had a recursive call that would do that. But this also prohibits call that would check for the root ACLs, so need to make it a bit less strict. --- src/acl.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/acl.js b/src/acl.js index 365a066aa..3fc83582e 100644 --- a/src/acl.js +++ b/src/acl.js @@ -337,7 +337,7 @@ UI.acl.getACLorDefault = function (doc, callbackFunction) { } var right = uri.lastIndexOf('/') var left = uri.indexOf('/', uri.indexOf('//') + 2) - if (left >= right) { + if (left > right) { return callbackFunction(false, true, 404, 'Found no ACL resource') } uri = uri.slice(0, right + 1)