Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion mime-parse/src/constants.rs
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,24 @@ impl Atoms {
return Atoms::AUDIO_STAR;
}
},
3 => {
if sub == OGG {
return Atoms::AUDIO_OGG;
}
if sub == MP4 {
return Atoms::AUDIO_MP4;
}
}
4 => {
if sub == MPEG {
return Atoms::AUDIO_MPEG;
}
},
5 => {
if sub == BASIC {
return Atoms::AUDIO_BASIC;
}
},
_ => (),
}
}
Expand Down Expand Up @@ -467,6 +485,11 @@ mimes! {
APPLICATION_PDF, "application/pdf", 11;
APPLICATION_DNS, "application/dns-message", 11;

AUDIO_BASIC, "audio/basic", 5;
AUDIO_MPEG, "audio/mpeg", 5;
AUDIO_MP4, "audio/mp4", 5;
AUDIO_OGG, "audio/ogg", 5;

// media-ranges
//@ MediaRange:
STAR_STAR, "*/*", 1;
Expand All @@ -475,4 +498,3 @@ mimes! {
VIDEO_STAR, "video/*", 5;
AUDIO_STAR, "audio/*", 5;
}

6 changes: 5 additions & 1 deletion src/constants.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,11 @@ mimes! {
APPLICATION_PDF, "application/pdf";
APPLICATION_DNS, "application/dns-message";

AUDIO_BASIC, "audio/basic";
AUDIO_MPEG, "audio/mpeg";
AUDIO_MP4, "audio/mp4";
AUDIO_OGG, "audio/ogg";

// media-ranges
@ MediaRange:
STAR_STAR, "*/*";
Expand All @@ -118,4 +123,3 @@ mimes! {
VIDEO_STAR, "video/*";
AUDIO_STAR, "audio/*";
}