From fed3fa14d1acb0a6285eaf4dd1a0f3b37eb36ed6 Mon Sep 17 00:00:00 2001 From: alimpens Date: Mon, 16 Sep 2024 14:27:29 +0200 Subject: [PATCH 1/2] Reduce geosearch distance --- src/shared/services/reverse-geocoder/reverse-geocoder.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/services/reverse-geocoder/reverse-geocoder.ts b/src/shared/services/reverse-geocoder/reverse-geocoder.ts index 5a0e653557..5904d95405 100644 --- a/src/shared/services/reverse-geocoder/reverse-geocoder.ts +++ b/src/shared/services/reverse-geocoder/reverse-geocoder.ts @@ -17,7 +17,7 @@ export const serviceURL = `${configuration.map.pdok.reverse}?type=adres&rows=1&f export const formatRequest = ( baseUrl: URL | string, wgs84point: LatLngLiteral, - distance = 50 + distance = 30 ) => { const { x, y } = wgs84ToRd(wgs84point) return `${new URL(baseUrl).toString()}&X=${x}&Y=${y}&distance=${distance}` From fbd274749d6049b4b79d7d16b6ec935dde6a1fc3 Mon Sep 17 00:00:00 2001 From: alimpens Date: Mon, 16 Sep 2024 14:45:57 +0200 Subject: [PATCH 2/2] Update test --- src/shared/services/reverse-geocoder/reverse-geocoder.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/services/reverse-geocoder/reverse-geocoder.test.ts b/src/shared/services/reverse-geocoder/reverse-geocoder.test.ts index d24142e5bd..c8e97cd62b 100644 --- a/src/shared/services/reverse-geocoder/reverse-geocoder.test.ts +++ b/src/shared/services/reverse-geocoder/reverse-geocoder.test.ts @@ -17,7 +17,7 @@ describe('formatRequest', () => { it('should format correct without distance', () => { expect(formatRequest('https://base-url', testLocation)).toEqual( - `${result}50` + `${result}30` ) })