diff options
author | Julien Veyssier <eneiluj@posteo.net> | 2022-07-05 16:43:36 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-05 16:43:36 +0300 |
commit | de3504150c44af8b20bc7fad9810abc3be0b9839 (patch) | |
tree | e103f4680d8cfee3c63c509333e79470a19d1b68 /apps/files | |
parent | 991ff3c99c8bf9a407d62f06f09cc147495755a8 (diff) | |
parent | ca6a7245032e87f6d7f65c8e796cc0f176659677 (diff) |
Merge pull request #33111 from nextcloud/fix/url-absolute
Fix 404 when using index.php in the url
Diffstat (limited to 'apps/files')
-rw-r--r-- | apps/files/js/files.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files/js/files.js b/apps/files/js/files.js index 6aa871d99c0..8645719f82b 100644 --- a/apps/files/js/files.js +++ b/apps/files/js/files.js @@ -25,7 +25,9 @@ state.call.abort(); } state.dir = currentDir; - state.call = $.getJSON(OC.filePath('files','ajax','getstoragestats') + '?dir=' + encodeURIComponent(currentDir),function(response) { + state.call = $.getJSON(OC.generateUrl('apps/files/ajax/getstoragestats?dir={dir}', { + dir: currentDir, + }), function(response) { state.dir = null; state.call = null; Files.updateMaxUploadFilesize(response); @@ -37,7 +39,7 @@ }, _updateStorageQuotas: function() { var state = Files.updateStorageQuotas; - state.call = $.getJSON(OC.filePath('files','ajax','getstoragestats'),function(response) { + state.call = $.getJSON(OC.generateUrl('apps/files/ajax/getstoragestats'), function(response) { Files.updateQuota(response); }); }, |