With all mimetypes included..this will also make upgrade path easier. Thoughts?


azinck’s picture

I agree that we should create a new type to act as a catch-all. Application makes sense to me as providing an easier upgrade path, but perhaps the label should be "Other" because I don't think "Application" is as meaningful to most site admins.

I think we should add an option (maybe just a Drupal variable?) to select which type should act as a fallback. We might have to do a little trickery in file_type_delete() to ensure this variable is always pointing at a valid type (and the fact that types can be disabled my complicate matters, too). Regardless, if this can be made a simple variable then a simple change to file_get_type() to use that type if no other type is assigned should work easily enough.

The alternative approach would be to try to assign all mimetypes to our fallback file type but I think it's going to be too difficult to avoid having a given mimetype mapped to multiple types, which leads to the usually-undesirable step of forcing the user to select the desired file type for every upload.

azinck’s picture

Dave Reid’s picture

Issue summary:View changes
Status:Active» Closed (won't fix)

The problem is once you assign a file a file type, you cannot convert it to another file type. This is just not something that I'd like to support.