Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorVincent Petry <vincent@nextcloud.com>2022-09-01 18:45:37 +0300
committerGitHub <noreply@github.com>2022-09-01 18:45:37 +0300
commit199d9e5804ec94f5bc59b37a6d74e5a12f1b71c3 (patch)
tree9faa96220ba732a65b2f58a12cb1aa58dc324699 /apps
parent1443f2085a5bc7f17cbf565f4fdcc3e2cc18d193 (diff)
parent393c89142179454d731931e85399685237f2a1bc (diff)
Merge pull request #33332 from nextcloud/fix-handling-of-internal-errors-when-uploading-theming-files
Fix handling of internal errors when uploading theming files
Diffstat (limited to 'apps')
-rw-r--r--apps/theming/js/settings-admin.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/theming/js/settings-admin.js b/apps/theming/js/settings-admin.js
index b33beda43d8..9fd1639ec3e 100644
--- a/apps/theming/js/settings-admin.js
+++ b/apps/theming/js/settings-admin.js
@@ -128,7 +128,8 @@ window.addEventListener('DOMContentLoaded', function () {
},
fail: function (e, response){
var $form = $(e.target).closest('form');
- OC.msg.finishedError('#theming_settings_msg', response._response.jqXHR.responseJSON.data.message);
+ const responseJSON = response._response.jqXHR.responseJSON;
+ OC.msg.finishedError('#theming_settings_msg', responseJSON && responseJSON.data && responseJSON.data.message ? responseJSON.data.message : t('theming', 'Error uploading the file'));
$form.find('label.button').addClass('icon-upload').removeClass('icon-loading-small');
$('#theming_settings_loading').hide();
}