mirror of
https://github.com/CommunitySolidServer/CommunitySolidServer.git
synced 2024-10-03 14:55:10 +00:00
change: Rename resourceStore to aclStore.
This commit is contained in:
parent
0b4e688359
commit
60fc273ea5
@ -12,7 +12,7 @@
|
|||||||
"aclStrategy": {
|
"aclStrategy": {
|
||||||
"@id": "urn:solid-server:default:AclStrategy"
|
"@id": "urn:solid-server:default:AclStrategy"
|
||||||
},
|
},
|
||||||
"resourceStore": {
|
"aclStore": {
|
||||||
"@id": "urn:solid-server:default:ResourceStore"
|
"@id": "urn:solid-server:default:ResourceStore"
|
||||||
},
|
},
|
||||||
"identifierStrategy": {
|
"identifierStrategy": {
|
||||||
|
@ -37,15 +37,15 @@ export class WebAclAuthorizer extends Authorizer {
|
|||||||
protected readonly logger = getLoggerFor(this);
|
protected readonly logger = getLoggerFor(this);
|
||||||
|
|
||||||
private readonly aclStrategy: AuxiliaryIdentifierStrategy;
|
private readonly aclStrategy: AuxiliaryIdentifierStrategy;
|
||||||
private readonly resourceStore: ResourceStore;
|
private readonly aclStore: ResourceStore;
|
||||||
private readonly identifierStrategy: IdentifierStrategy;
|
private readonly identifierStrategy: IdentifierStrategy;
|
||||||
private readonly accessChecker: AccessChecker;
|
private readonly accessChecker: AccessChecker;
|
||||||
|
|
||||||
public constructor(aclStrategy: AuxiliaryIdentifierStrategy, resourceStore: ResourceStore,
|
public constructor(aclStrategy: AuxiliaryIdentifierStrategy, aclStore: ResourceStore,
|
||||||
identifierStrategy: IdentifierStrategy, accessChecker: AccessChecker) {
|
identifierStrategy: IdentifierStrategy, accessChecker: AccessChecker) {
|
||||||
super();
|
super();
|
||||||
this.aclStrategy = aclStrategy;
|
this.aclStrategy = aclStrategy;
|
||||||
this.resourceStore = resourceStore;
|
this.aclStore = aclStore;
|
||||||
this.identifierStrategy = identifierStrategy;
|
this.identifierStrategy = identifierStrategy;
|
||||||
this.accessChecker = accessChecker;
|
this.accessChecker = accessChecker;
|
||||||
}
|
}
|
||||||
@ -172,7 +172,7 @@ export class WebAclAuthorizer extends Authorizer {
|
|||||||
try {
|
try {
|
||||||
const acl = this.aclStrategy.getAuxiliaryIdentifier(id);
|
const acl = this.aclStrategy.getAuxiliaryIdentifier(id);
|
||||||
this.logger.debug(`Trying to read the ACL document ${acl.path}`);
|
this.logger.debug(`Trying to read the ACL document ${acl.path}`);
|
||||||
const data = await this.resourceStore.getRepresentation(acl, { type: { [INTERNAL_QUADS]: 1 }});
|
const data = await this.aclStore.getRepresentation(acl, { type: { [INTERNAL_QUADS]: 1 }});
|
||||||
this.logger.info(`Reading ACL statements from ${acl.path}`);
|
this.logger.info(`Reading ACL statements from ${acl.path}`);
|
||||||
|
|
||||||
return await this.filterData(data, recurse ? ACL.default : ACL.accessTo, id.path);
|
return await this.filterData(data, recurse ? ACL.default : ACL.accessTo, id.path);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user