Skip to content

Commit

Permalink
fix: use direct link to opendata, as axios wont follow redirects behi…
Browse files Browse the repository at this point in the history
…nd proxy
  • Loading branch information
nojhamster committed Mar 29, 2021
1 parent 9f727b0 commit f55780c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion api/lib/services/opendata.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,13 @@ async function recreateIndex() {
async function update() {
const { data } = await axios({
method: 'get',
url: 'https://www.data.gouv.fr/fr/datasets/r/5fb6d2e3-609c-481d-9104-350e9ca134fa',
// url: 'https://www.data.gouv.fr/fr/datasets/r/5fb6d2e3-609c-481d-9104-350e9ca134fa',
url: 'https://data.enseignementsup-recherche.gouv.fr/explore/dataset/fr-esr-principaux-etablissements-enseignement-superieur/download',
params: {
format: 'json',
timezone: 'Europe/Berlin',
use_labels_for_header: false,
},
timeout: 30000,
headers: {
'Application-ID': 'ezMESURE',
Expand Down

0 comments on commit f55780c

Please sign in to comment.