Re: [FileAPI] File.mediaType

>>> Returning "application/octet-stream" rather than null also seems better
>>> if the type is not known. That way you do not have to type check. Other
>>> parts of the platform also handle "application/octet-stream" as unknown.
>>
>> It's been pointed out that user agents type check on files.  If the
>> mediaType is not known, users invoking the attribute can't do anything
>> useful with it, so null is better.  What are the use cases for using
>> application/octet-stream instead?
>
> I guess not known might be useful. Can't we just make it the empty string
> then? I don't really see the need to return something other than a
> DOMString.

I agree an empty string is just as good here.

/ Jonas

Received on Monday, 16 November 2009 18:36:56 UTC