throttle requests if status != 200
This commit is contained in:
parent
1d823af134
commit
105a063acf
@ -14,7 +14,7 @@ export default (context, inject) => {
|
|||||||
store.commit('engine/setJson', json)
|
store.commit('engine/setJson', json)
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
const { status, statusText } = e.response
|
const { status, statusText } = e.response
|
||||||
if (status >= 500) {
|
if (status != 200) {
|
||||||
console.warn(`HTTP ${status} ${statusText}`)
|
console.warn(`HTTP ${status} ${statusText}`)
|
||||||
delay = 5000
|
delay = 5000
|
||||||
store.commit('engine/setVersion', -1)
|
store.commit('engine/setVersion', -1)
|
||||||
|
Loading…
Reference in New Issue
Block a user