diff --git a/src/structures/services/structures.service.ts b/src/structures/services/structures.service.ts index dc29aaa909fb3af0d9471bff2bc3b9f9ec4d1a1e..9bc4fea5687444ef02c0c325aaaf68037dd1086b 100644 --- a/src/structures/services/structures.service.ts +++ b/src/structures/services/structures.service.ts @@ -151,8 +151,6 @@ export class StructuresService { * Search structure address based on data search WS */ public async searchAddress(data: { searchQuery: string }): Promise<AxiosResponse<any>> { - data.searchQuery = data.searchQuery.replace('à', 'a'); - data.searchQuery = data.searchQuery.replace(/é|è/g, 'e'); const req = 'https://download.data.grandlyon.com/geocoding/photon-bal/api?q=' + data.searchQuery + @@ -160,7 +158,7 @@ export class StructuresService { return new Promise((resolve, reject) => { this.httpService .request({ - url: req, + url: encodeURI(req), method: 'GET', headers: { 'Content-Type': 'application/json' }, })