diff --git a/client/modules/IDE/reducers/files.js b/client/modules/IDE/reducers/files.js index 9be4667e..404a1aee 100644 --- a/client/modules/IDE/reducers/files.js +++ b/client/modules/IDE/reducers/files.js @@ -227,7 +227,12 @@ const files = (state, action) => { return file; }); default: - return state; + return state.map((file) => { + if (file.name === 'root') { + file.children = sortedChildrenId(state, file.children); + } + return file; + }); } };