From 60c522899bcfd3aef1a486922e0a9aeb549c0fc8 Mon Sep 17 00:00:00 2001 From: adev Date: Sun, 14 May 2017 11:38:02 +0200 Subject: Fix delete annotation when username is defined When an user set his name in "Config" > "User Information", he can't delete or update an annotation Fix #2382 --- app/Resources/static/themes/_global/index.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'app/Resources/static') diff --git a/app/Resources/static/themes/_global/index.js b/app/Resources/static/themes/_global/index.js index 00410754..3fdcaa3d 100644 --- a/app/Resources/static/themes/_global/index.js +++ b/app/Resources/static/themes/_global/index.js @@ -28,6 +28,11 @@ $(document).ready(() => { element: document.querySelector('article'), }); + const authorization = { + permits() { return true; }, + }; + app.registry.registerUtility(authorization, 'authorizationPolicy'); + const x = JSON.parse($('#annotationroutes').html()); app.include(annotator.storage.http, x); -- cgit v1.2.3