Skip to content
Snippets Groups Projects
Commit 8d736ae1 authored by Hugo SUBTIL's avatar Hugo SUBTIL
Browse files

fix(carto): improve perf for isClaim request, only requesting if user is an admin

parent 7243ed28
No related branches found
No related tags found
3 merge requests!418V2.1.0,!400V2.0,!230V2.0
......@@ -116,7 +116,9 @@ export class CartoComponent implements OnInit {
structures.map(async (structure) => {
if (this.geolocation) {
structure = this.getStructurePosition(structure, lon, lat);
structure.isClaimed = await this.isClaimed(structure).toPromise();
if (this.isAdmin) {
structure.isClaimed = await this.isClaimed(structure).toPromise();
}
}
return structure;
})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment