small fixes on example

This commit is contained in:
timurgordon
2025-02-18 05:22:38 +03:00
parent 906f13b562
commit 6305cf159e
3 changed files with 8 additions and 8 deletions

View File

@@ -2,15 +2,15 @@
import freeflowuniverse.herolib.vfs.webdav
import freeflowuniverse.herolib.vfs.vfsnested
import freeflowuniverse.herolib.vfs.ourdb_fs
import freeflowuniverse.herolib.vfs.vfscore
import freeflowuniverse.herolib.vfs.vfsourdb
mut high_level_vfs := vfsnested.new()
// lower level VFS Implementations that use OurDB
mut vfs1 := vfscore.new_local_vfs('/tmp/test_webdav_ourdbvfs/vfs1')!
mut vfs2 := vfscore.new_local_vfs('/tmp/test_webdav_ourdbvfs/vfs2')!
mut vfs3 := vfscore.new_local_vfs('/tmp/test_webdav_ourdbvfs/vfs3')!
mut vfs1 := vfsourdb.new('/tmp/test_webdav_ourdbvfs/vfs1', '/tmp/test_webdav_ourdbvfs/vfs1')!
mut vfs2 := vfsourdb.new('/tmp/test_webdav_ourdbvfs/vfs2', '/tmp/test_webdav_ourdbvfs/vfs2')!
mut vfs3 := vfsourdb.new('/tmp/test_webdav_ourdbvfs/vfs3', '/tmp/test_webdav_ourdbvfs/vfs3')!
// Nest OurDB VFS instances at different paths
high_level_vfs.add_vfs('/data', vfs1) or { panic(err) }
@@ -20,4 +20,4 @@ high_level_vfs.add_vfs('/data/backup', vfs3) or { panic(err) } // Nested under /
// Create WebDAV Server that uses high level VFS
webdav_server := webdav.new_app(
vfs: high_level_vfs
)
)!