mirror of
https://github.com/nocodb/nocodb.git
synced 2026-05-04 10:27:03 +00:00
feat: use new attachment api
Signed-off-by: Pranav C <pranavxc@gmail.com>
This commit is contained in:
@@ -12,8 +12,8 @@ const imageExt = [
|
||||
|
||||
export default imageExt
|
||||
|
||||
const isImage = (name) => {
|
||||
return imageExt.some(e => name.toLowerCase().endsWith(`.${e}`))
|
||||
const isImage = (name, type) => {
|
||||
return imageExt.some(e => name.toLowerCase().endsWith(`.${e}`)) || (type || '').startsWith('image/')
|
||||
}
|
||||
|
||||
export { isImage }
|
||||
|
||||
Reference in New Issue
Block a user