Skip to content

Commit 329e932

Browse files
committed
chore(storage): update upload route
1 parent 28d97fa commit 329e932

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/api/storage/upload.post.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default eventHandler(async (event) => {
99
throw createError({ status: 400, message: 'No file provided' })
1010
}
1111

12-
if (file.type !== 'image/png' && file.type !== 'image/jpeg') {
12+
if (!file.type.startsWith('image/')) {
1313
throw createError({ status: 400, message: 'File must be an image' })
1414
}
1515

0 commit comments

Comments
 (0)