File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -486,7 +486,7 @@ export class LocalApi implements FsApi {
486486
487487export function FolderExists ( path : string ) : boolean {
488488 try {
489- return fs . existsSync ( path ) && fs . lstatSync ( path ) . isDirectory ( )
489+ return fs . existsSync ( path ) && fs . statSync ( path ) . isDirectory ( )
490490 } catch ( err ) {
491491 return false
492492 }
@@ -501,8 +501,9 @@ export const FsLocal: Fs = {
501501 readonly : false ,
502502 indirect : false ,
503503 } ,
504- canread ( basePath : string ) : boolean {
505- return ! ! basePath . match ( localStart )
504+ canread ( basePath : string , subDir : string ) : boolean {
505+ const fullPath = path . join ( basePath , subDir )
506+ return ! ! basePath . match ( localStart ) && FolderExists ( fullPath )
506507 } ,
507508 serverpart ( str : string ) : string {
508509 return 'local'
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ export default function initFS() {
1414 } else {
1515 // TODO: there should be an easy way to automatically register new FS
1616 registerFs ( FsWsl )
17- registerFs ( FsZip )
1817 registerFs ( FsLocal )
18+ registerFs ( FsZip )
1919 }
2020}
You can’t perform that action at this time.
0 commit comments