[Webkit-unassigned] [Bug 170674] File API constructor filename ignored

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed May 23 16:32:50 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=170674

--- Comment #3 from ebrommers at gmail.com ---
(In reply to ebrommers from comment #2)
> Related issue, so I'll add it here instead of creating a new issue. 
> 
> When you create a File object using a string value (iOS 11.3), that value
> ends up populating the name property instead of the name passed in.
> 
> 
> ```
> var myFile = new File(["Something wrong here"], "myFileName", {type:
> "text/plain"});
> ```
> 
> looking at myFile.name in the debugger gives an array value with "Something
> wrong here" as element[0]; the value for "myFileName" ends up in another
> attribute "localURL".

Update: it looks like passing in a blob instead of a string value does the same thing. Somewhere File.name is getting assigned the value of the first parameter in the constructor (which should be the contents of the file, if I'm reading the spec correctly).

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180523/9bb8cdf0/attachment-0001.html>


More information about the webkit-unassigned mailing list