mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-25 20:03:12 +03:00
🐛 Fixed missing errors on failed import
no issue - bug was introduced in https://github.com/TryGhost/Ghost-Admin/pull/902 where the change to `response.payload.errors` from `error.errors` was missed
This commit is contained in:
parent
18614c39f6
commit
93071cb2e4
@ -156,13 +156,14 @@ export default Controller.extend({
|
||||
});
|
||||
}).catch((response) => {
|
||||
if (isUnsupportedMediaTypeError(response) || isRequestEntityTooLargeError(response)) {
|
||||
this.set('importErrors', [response]);
|
||||
return;
|
||||
return this.set('importErrors', [response]);
|
||||
}
|
||||
|
||||
if (response && response.errors && isEmberArray(response.errors)) {
|
||||
this.set('importErrors', response.errors);
|
||||
if (response && response.payload.errors && isEmberArray(response.payload.errors)) {
|
||||
return this.set('importErrors', response.payload.errors);
|
||||
}
|
||||
|
||||
throw response;
|
||||
}).finally(() => {
|
||||
this.set('uploadButtonText', 'Import');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user