MCPcopy Index your code
hub / github.com/anomalyco/opencode / isMedia

Function isMedia

packages/opencode/src/util/media.ts:7–9  ·  view source on GitHub ↗
(mime: string)

Source from the content-addressed store, hash-verified

5}
6
7export function isMedia(mime: string) {
8 return mime.startsWith("image/") || isPdfAttachment(mime)
9}
10
11export function isImageAttachment(mime: string) {
12 return mime.startsWith("image/") && mime !== "image/svg+xml" && mime !== "image/vnd.fastbidsheet"

Callers 1

message-v2.tsFile · 0.90

Calls 1

isPdfAttachmentFunction · 0.85

Tested by

no test coverage detected