Browse Source

[frontend] Add knox prefix to download url

Björn Alm 2 years ago
parent
commit
16c82c9e32
1 changed files with 2 additions and 1 deletions
  1. 2 1
      desktop/core/src/desktop/js/onePageViewModel.js

+ 2 - 1
desktop/core/src/desktop/js/onePageViewModel.js

@@ -894,7 +894,8 @@ class OnePageViewModel {
         // The download view on the backend requires the slashes not to
         // be encoded in order for the file to be correctly named.
         const encodedPath = encodeURIComponent(decodedPath).replaceAll('%2F', '/');
-        window.location = pathPrefix + encodedPath;
+        const possibleKnoxUrlPathPrefix = window.HUE_BASE_URL;
+        window.location = possibleKnoxUrlPathPrefix + pathPrefix + encodedPath;
         return;
       }