Commit 849b37a1 authored by Dietmar Maurer's avatar Dietmar Maurer

display correct error message on file uploads

parent cb39891f
......@@ -269,7 +269,10 @@ Ext.define('PVE.storage.Upload', {
me.close();
} else {
var msg = "Error " + xhr.status.toString() + ": " + Ext.htmlEncode(xhr.statusText);
Ext.Msg.alert(gettext('Error'), msg, function(btn) {
var result = Ext.decode(xhr.responseText);
result.message = msg;
var htmlStatus = PVE.Utils.extractRequestError(result, true);
Ext.Msg.alert(gettext('Error'), htmlStatus, function(btn) {
me.close();
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment