mirror of
https://github.com/haiwen/seahub.git
synced 2025-04-27 11:01:14 +00:00
fix special folder judgement (#7749)
Co-authored-by: 孙永强 <11704063+s-yongqiang@user.noreply.gitee.com>
This commit is contained in:
parent
f24516e88a
commit
e11dd9e34c
@ -21,7 +21,8 @@ const DirDetails = ({ direntDetail }) => {
|
||||
let size = Utils.bytesToSize(direntDetail.size);
|
||||
let special_folder = false;
|
||||
if (direntDetail.path !== undefined) {
|
||||
special_folder = SYSTEM_FOLDERS.some(folder => direntDetail.path.startsWith(folder));
|
||||
const path = direntDetail.path;
|
||||
special_folder = SYSTEM_FOLDERS.some(prefix => path === prefix || path.startsWith(prefix + '/'));
|
||||
}
|
||||
|
||||
return (
|
||||
|
Loading…
Reference in New Issue
Block a user