Prevent a double file manager load
This commit is contained in:
parent
0b9c6bd21d
commit
de464d35a2
1 changed files with 2 additions and 2 deletions
|
@ -24,7 +24,7 @@ const files: ServerFileStore = {
|
|||
|
||||
const contents = await loadDirectory(server.uuid, payload);
|
||||
|
||||
actions.setDirectory(payload);
|
||||
actions.setDirectory(payload.length === 0 ? '/' : payload);
|
||||
actions.setContents(contents);
|
||||
}),
|
||||
|
||||
|
@ -47,7 +47,7 @@ const files: ServerFileStore = {
|
|||
}),
|
||||
|
||||
setDirectory: action((state, payload) => {
|
||||
state.directory = payload;
|
||||
state.directory = payload.length === 0 ? '/' : payload;
|
||||
}),
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue