Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use "facets" to resolve extension conflicts #160

Closed
broofa opened this issue Jun 15, 2017 · 0 comments
Closed

Use "facets" to resolve extension conflicts #160

broofa opened this issue Jun 15, 2017 · 0 comments
Labels

Comments

@broofa
Copy link
Owner

broofa commented Jun 15, 2017

mime-db contains a number of inconsistencies where multiple mime types are defined for the same extension. These should be resolved as part of creating the types.json file, and the define() api should require callers to be explicit about whether or not it's okay to override an existing definition.

$ DEBUG_MIME=1 node
> require('mime')
define() changes "dmg" extension type from application/octet-stream to application/x-apple-diskimage
define() changes "bdoc" extension type from application/bdoc to application/x-bdoc
define() changes "deb" extension type from application/octet-stream to application/x-debian-package
define() changes "iso" extension type from application/octet-stream to application/x-iso9660-image
define() changes "exe" extension type from application/octet-stream to application/x-msdos-program
define() changes "exe" extension type from application/x-msdos-program to application/x-msdownload
define() changes "dll" extension type from application/octet-stream to application/x-msdownload
define() changes "msi" extension type from application/octet-stream to application/x-msdownload
define() changes "wmz" extension type from application/x-ms-wmz to application/x-msmetafile
define() changes "prc" extension type from application/x-mobipocket-ebook to application/x-pilot
define() changes "pdb" extension type from application/vnd.palm to application/x-pilot
define() changes "mp3" extension type from audio/mp3 to audio/mpeg
define() changes "wav" extension type from audio/wav to audio/wave
define() changes "m4a" extension type from audio/mp4 to audio/x-m4a
define() changes "ra" extension type from audio/x-pn-realaudio to audio/x-realaudio
define() changes "wav" extension type from audio/wave to audio/x-wav
define() changes "otf" extension type from application/x-font-otf to font/opentype
define() changes "bmp" extension type from image/bmp to image/x-ms-bmp
define() changes "rtf" extension type from application/rtf to text/rtf
define() changes "sub" extension type from image/vnd.dvb.subtitle to text/vnd.dvb.subtitle
define() changes "xml" extension type from application/xml to text/xml
define() changes "3gpp" extension type from audio/3gpp to video/3gpp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant