Merge pull request #15 from abraham/catch

Display error message
This commit is contained in:
Liyas Thomas 2019-08-23 02:09:27 +05:30 committed by GitHub
commit 0c78f29907
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -136,6 +136,10 @@ const app = new Vue({
this.response.body = xhr.responseText
}
}
xhr.onerror = e => {
this.response.status = '0'
this.response.body = 'Error ;('
}
},
addRequestParam() {
this.params.push({