fix: stabilize pty tests and media kind

This commit is contained in:
Peter Steinberger
2026-01-17 08:10:44 +00:00
parent cccd7c7b8e
commit c5239f6a8e
3 changed files with 4 additions and 4 deletions

View File

@@ -104,7 +104,7 @@ export function resolveAttachmentKind(
attachment: MediaAttachment,
): "image" | "audio" | "video" | "document" | "unknown" {
const kind = kindFromMime(attachment.mime);
if (kind !== "unknown") return kind;
if (kind === "image" || kind === "audio" || kind === "video") return kind;
const ext = getFileExtension(attachment.path ?? attachment.url);
if (!ext) return "unknown";