Skip to content

Commit be6fc34

Browse files
committed
feat: update analytics api version and remove deprecated api
1 parent 66a418e commit be6fc34

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

api/analytics.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ export default axios => ({
1010
},
1111

1212
// deprecating
13-
fetchAffectedCountry: () => {
14-
return axios.get(`/v2/analytics/country`).then(res => res.data)
15-
},
13+
// fetchAffectedCountry: () => {
14+
// return axios.get(`/v2/analytics/country`).then(res => res.data)
15+
// },
1616

1717
fetchTopCountryWithDailyNewStatsSortByNewCases: () => {
18-
return axios.get(`/v3/analytics/dailyNewStats`).then(res => res.data)
18+
return axios.get(`/v5/analytics/dailyNewStats`).then(res => res.data)
1919
}
2020
})

api/stats.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export default axios => ({
5555
}
5656

5757
return axios
58-
.get(`/v4/analytics/trend/country`, { params })
58+
.get(`/v5/analytics/trend/country`, { params })
5959
.then(res => res.data)
6060
},
6161

@@ -67,7 +67,7 @@ export default axios => ({
6767
}
6868

6969
return axios
70-
.get(`/v4/analytics/newcases/country`, { params })
70+
.get(`/v5/analytics/newcases/country`, { params })
7171
.then(res => res.data)
7272
}
7373
})

0 commit comments

Comments
 (0)