This commit is contained in:
+2
-2
@@ -7,8 +7,8 @@ const writable = await file_handle.createWritable()
|
||||
writable.write('Hello World!')
|
||||
writable.close()
|
||||
const file = await file_handle.getFile()
|
||||
const file_text = await file.text()
|
||||
console.log(file_text)
|
||||
console.log(file.type)
|
||||
console.log(await file.text())
|
||||
const result = await cwd_directory_handle.getFileHandle('test/test.txt').catch(error => 'blocked path traversal')
|
||||
if (typeof result === 'string') console.log(result)
|
||||
else console.error('path traversal not blocked')
|
||||
|
||||
Reference in New Issue
Block a user