From abe28c84b05401ad06d396e2aa6f9b29c0def7e5 Mon Sep 17 00:00:00 2001 From: Morilli <35152647+Morilli@users.noreply.github.com> Date: Thu, 9 Jan 2020 15:45:19 +0100 Subject: [PATCH] Improve swagger error message and remove an unused variable --- app/index.html | 1 - app/swagger-ui.js | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/index.html b/app/index.html index e8536e2..a87b3bd 100644 --- a/app/index.html +++ b/app/index.html @@ -40,7 +40,6 @@ const messageBar = document.querySelector('#message-bar'); let LCUData = null; - let swaggerDisabled = true; // We all love global variables window.RE = { diff --git a/app/swagger-ui.js b/app/swagger-ui.js index 2ecabc3..e88f299 100644 --- a/app/swagger-ui.js +++ b/app/swagger-ui.js @@ -1289,7 +1289,7 @@ SwaggerClient.prototype.build = function (mock) { } else if (response.status === 0) { return self.fail('Can\'t read from server. It may not have the appropriate access-control-origin settings.'); } else if (response.status === 404) { - return self.fail('Can\'t load Swagger. Make sure it\'s enabled in system.yaml'); + return self.fail('Can\'t load Swagger. Make sure to leave the system.yaml unmodified and try restarting.'); } else { return self.fail(response.status + ' : ' + response.statusText + ' ' + self.url); }