fix getFile with err
This commit is contained in:
parent
94469c4d5e
commit
aa19c76235
1 changed files with 6 additions and 2 deletions
|
@ -308,8 +308,12 @@ export async function getFile(path: string): Promise<any> {
|
|||
path: path
|
||||
}
|
||||
let url = '/api/file/getFile';
|
||||
try {
|
||||
let file = await fetchSyncPost(url, data);
|
||||
return file;
|
||||
} catch (error_msg) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
export async function putFile(path: string, isDir: boolean, file: any) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue