From 69e8bd736923d41249eb1bbe59bd86c679e33382 Mon Sep 17 00:00:00 2001 From: Bouillaguet Quentin Date: Sat, 16 Nov 2024 10:36:48 +0100 Subject: [PATCH] fix(Crs): correctly renamed reasonableEpsilon function --- src/Core/Geographic/Crs.ts | 4 ++-- src/Core/Geographic/Extent.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Core/Geographic/Crs.ts b/src/Core/Geographic/Crs.ts index 311967dc35..b53f2cee96 100644 --- a/src/Core/Geographic/Crs.ts +++ b/src/Core/Geographic/Crs.ts @@ -177,12 +177,12 @@ export function isValid(crs: ProjectionLike) { } /** - * Gives a reasonnable epsilon for this CRS. + * Gives a reasonable epsilon for this CRS. * * @param crs - The CRS to use. * @returns 0.01 if the CRS is EPSG:4326, 0.001 otherwise. */ -export function reasonnableEpsilon(crs: ProjectionLike) { +export function reasonableEpsilon(crs: ProjectionLike) { if (is4326(crs)) { return 0.01; } else { diff --git a/src/Core/Geographic/Extent.js b/src/Core/Geographic/Extent.js index 0fa844dfdb..10482b7fa9 100644 --- a/src/Core/Geographic/Extent.js +++ b/src/Core/Geographic/Extent.js @@ -234,7 +234,7 @@ class Extent { */ isInside(extent, epsilon) { extent.as(this.crs, _extent); - epsilon = epsilon == undefined ? CRS.reasonnableEpsilon(this.crs) : epsilon; + epsilon = epsilon ?? CRS.reasonableEpsilon(this.crs); return this.east - _extent.east <= epsilon && _extent.west - this.west <= epsilon && this.north - _extent.north <= epsilon &&