Fix the type of argument to mimetypes functions