From 776de0be46693071e9f1640e8f20b870cada52d3 Mon Sep 17 00:00:00 2001 From: Matthias Mohr Date: Fri, 15 Mar 2024 10:56:42 +0100 Subject: [PATCH] Implement temporary workaround for https://github.com/OSGeo/PROJ/issues/4088 --- src/loader/default.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/loader/default.js b/src/loader/default.js index 2a95417..0a748ac 100644 --- a/src/loader/default.js +++ b/src/loader/default.js @@ -1,6 +1,12 @@ const axios = require('axios'); async function loader(uri) { + // Todo: Temporary workaround for https://github.com/OSGeo/PROJ/issues/4088 + const projjson = uri.startsWith('https://proj.org/schemas/'); + if (projjson) { + uri = uri.replace('https://proj.org/schemas/', 'https://proj.org/en/latest/schemas/'); + } + let response = await axios.get(uri); return response.data; }