From cd10b56aa64b58aa3237780c2d0b1f972ca07fb2 Mon Sep 17 00:00:00 2001 From: Abraham Williams <4braham@gmail.com> Date: Thu, 22 Aug 2019 15:34:17 -0500 Subject: [PATCH] Display error message --- script.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/script.js b/script.js index b2c082a02..ea38ac3f1 100644 --- a/script.js +++ b/script.js @@ -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({