mirror of
https://github.com/ducbao414/win32.run.git
synced 2025-12-17 09:42:50 +09:00
migrate: remove .files, .folders, use .children instead
This commit is contained in:
@@ -21,11 +21,11 @@
|
||||
let page_index = 0;
|
||||
$: url = finder.to_url(history[page_index]) || 'My Computer';
|
||||
|
||||
|
||||
$: folders = $hardDrive[id] == null ? [] : $hardDrive[id].folders.map(id => $hardDrive[id]);
|
||||
$: files = $hardDrive[id] == null ? [] : $hardDrive[id].files.map(id => $hardDrive[id]);
|
||||
|
||||
$: items = [...files, ...folders]
|
||||
$: items = $hardDrive[id] == null ?
|
||||
[] :
|
||||
$hardDrive[id]
|
||||
.children
|
||||
.map(id => $hardDrive[id])
|
||||
.filter(el => el != null)
|
||||
.filter(el => !hidden_items.includes(el.id));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user