From fc93517fc5b42da57f72353f96f95dde5314646f Mon Sep 17 00:00:00 2001 From: Daniel Calviño Sánchez Date: Mon, 29 Jul 2024 12:08:55 +0200 Subject: refactor: Store result in its own variable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Daniel Calviño Sánchez --- apps/files_external/js/settings.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/files_external/js/settings.js b/apps/files_external/js/settings.js index 30bf85a6764..e1d47dbdc89 100644 --- a/apps/files_external/js/settings.js +++ b/apps/files_external/js/settings.js @@ -981,9 +981,10 @@ MountConfigListView.prototype = _.extend({ data: {'testOnly' : true}, contentType: 'application/json', success: function(result) { + result = Object.values(result); var onCompletion = jQuery.Deferred(); var $rows = $(); - Object.values(result).forEach(function(storageParams) { + result.forEach(function(storageParams) { var storageConfig; var isUserGlobal = storageParams.type === 'system' && self._isPersonal; storageParams.mountPoint = storageParams.mountPoint.substr(1); // trim leading slash -- cgit v1.2.3