Skip to content

Commit

Permalink
Implement temporary workaround for OSGeo/PROJ#4088
Browse files Browse the repository at this point in the history
  • Loading branch information
m-mohr committed Mar 15, 2024
1 parent 798731f commit 776de0b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/loader/default.js
Original file line number Diff line number Diff line change
@@ -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;
}
Expand Down

0 comments on commit 776de0b

Please sign in to comment.