boolean bAdmin = auth.getAuthenticatedRoles().hasRole("gptAdministrator");
if (!bAdmin) {
MetadataAcl acl = new MetadataAcl(rContext);
if (!acl.isPolicyUnrestricted()) {
LuceneIndexAdapter adapter = new LuceneIndexAdapter(rContext);
String[] resourceAcls = adapter.queryAcls(resourceId);
if ((resourceAcls != null) && (resourceAcls.length > 0)) {
String[] userAcls = acl.makeUserAcl();
if ((userAcls != null) && (userAcls.length > 0)) {
for (String resourcePrincipal: resourceAcls) {