Fix recursion to ensure error message displayed after 3 failed contribution attempts

This commit is contained in:
bennylada 2021-05-25 19:14:40 +00:00
parent 68c813013d
commit 9f2d7f67fa
1 changed files with 2 additions and 1 deletions

View File

@ -241,7 +241,8 @@ export default {
} else if (resp.status === 422) {
if (retry < 3) {
console.log(`Looks like someone else uploaded contribution ahead of us, retrying`)
await this.makeContribution({ userInput, retry: retry++ })
console.log('Attempt ', retry+1)
await this.makeContribution({ userInput, retry: ++retry })
} else {
this.status.msg =
this.$t('pages.contribution.failedUpload') +