mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2025-02-17 00:21:20 -05:00
Merge pull request #2393 from benjiwheeler/update-project-error
project page will no longer vanish when project metadata update fails on the backend
This commit is contained in:
commit
93b04a59f1
1 changed files with 2 additions and 2 deletions
|
@ -754,9 +754,9 @@ module.exports.updateProject = (id, jsonData, username, token) => (dispatch => {
|
|||
dispatch(module.exports.setError('No project info'));
|
||||
return;
|
||||
}
|
||||
if (res.statusCode === 500) { // InternalServer
|
||||
if (res.statusCode >= 400) { // API responding with error
|
||||
dispatch(module.exports.setFetchStatus('project', module.exports.Status.ERROR));
|
||||
dispatch(module.exports.setError('API Internal Server Error'));
|
||||
dispatch(module.exports.setError('API Error Response'));
|
||||
return;
|
||||
}
|
||||
dispatch(module.exports.setFetchStatus('project', module.exports.Status.FETCHED));
|
||||
|
|
Loading…
Reference in a new issue