]> git.immae.eu Git - github/bastienwirtz/homer.git/commitdiff
feat(auth): do not handle redirection in getConfig
authorPierre <397503+bemble@users.noreply.github.com>
Mon, 30 May 2022 15:04:21 +0000 (17:04 +0200)
committerPierre <397503+bemble@users.noreply.github.com>
Mon, 30 May 2022 15:04:21 +0000 (17:04 +0200)
It will be handled by connectivity checker

src/App.vue

index 515177eba13b80d096a89727781655114dadf35d..a60c2426a03cdf19bc4a95c2af5a005b7fed872d 100644 (file)
@@ -231,13 +231,7 @@ export default {
     },
     getConfig: function (path = "assets/config.yml") {
       return fetch(path).then((response) => {
-        if (response.redirected) {
-          // This allows to work with authentication proxies.
-          window.location.href = response.url;
-          return;
-        }
-
-        if (response.status == 404) {
+        if (response.status == 404 || response.redirected) {
           this.configNotFound = true;
           return {};
         }