| commit | 00bf078950204d08fbc3bb39675707a532972151 | [log] [tgz] |
|---|---|---|
| author | Laurence Maultsby <laurence.maultsby@riftio.com> | Thu May 18 08:17:15 2017 -0400 |
| committer | kashalkar <kiran.kashalkar@riftio.com> | Thu May 18 14:52:46 2017 +0100 |
| tree | 167b62fbc9b04ddc88793dda49707be05f80165d | |
| parent | e7d2aea71cdb46033756e50acf20e6cf64e99597 [diff] |
Better error reporting on instantiate page Signed-off-by: Laurence Maultsby <laurence.maultsby@riftio.com> (cherry picked from commit c09a6948835c9e519829e44f20d649a0dc555f3e) Change-Id: I3ddc199db649edb6cbac4ca5ec2a032575a8567f
diff --git a/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js b/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js index b673e3a..0d9e1b6 100644 --- a/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js +++ b/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js
@@ -191,6 +191,9 @@ } launchNSRError(data) { var msg = 'Something went wrong while trying to instantiate. Check the error logs for more information'; + if(data) { + msg = data; + } if (data.error) { msg = data.error; }
diff --git a/skyquake/plugins/launchpad/src/instantiate/launchNetworkServiceSource.js b/skyquake/plugins/launchpad/src/instantiate/launchNetworkServiceSource.js index 6c5daaa..d5c33c1 100644 --- a/skyquake/plugins/launchpad/src/instantiate/launchNetworkServiceSource.js +++ b/skyquake/plugins/launchpad/src/instantiate/launchNetworkServiceSource.js
@@ -128,7 +128,7 @@ }).fail(function(xhr){ //Authentication and the handling of fail states should be wrapped up into a connection class. Utils.checkAuthentication(xhr.status); - var error; + var error = null; if(xhr.responseText) { try { error = JSON.parse(xhr.responseText);