mirror of
https://github.com/ArthurDanjou/artagents.git
synced 2026-01-30 11:47:56 +01:00
lint code
This commit is contained in:
@@ -7,7 +7,7 @@ export default eventHandler(async (event) => {
|
||||
const stream = await hubBlob().serve(event, `chats/${pathname}.json`)
|
||||
|
||||
if (!(stream instanceof ReadableStream)) {
|
||||
throw new Error('Le stream n\'est pas valide')
|
||||
throw new TypeError('Le stream n\'est pas valide')
|
||||
}
|
||||
|
||||
const read = await streamToText(stream)
|
||||
|
||||
@@ -8,11 +8,11 @@ export default eventHandler(async (event) => {
|
||||
|
||||
ensureBlob(file, {
|
||||
maxSize: '1MB',
|
||||
types: ['application/jsonml+json', 'application/json']
|
||||
types: ['application/jsonml+json', 'application/json'],
|
||||
})
|
||||
|
||||
return hubBlob().put(file.name, file, {
|
||||
addRandomSuffix: false,
|
||||
prefix: 'chats'
|
||||
prefix: 'chats',
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user