mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
13 lines
399 B
TypeScript
13 lines
399 B
TypeScript
import { err, ok } from "neverthrow"
|
|
|
|
export function allowedDocExtension(type: string) {
|
|
if (type == 'application/pdf' || type == 'application/doc' || type == 'application/docx' ||
|
|
type == 'application/xls' || type == 'application/xlsx' || type == 'application/ppt' ||
|
|
type == 'application/pptx' || type == 'application/txt') {
|
|
|
|
return ok(true)
|
|
} else {
|
|
return err(false)
|
|
}
|
|
}
|