idb.filesystem.js icon indicating copy to clipboard operation
idb.filesystem.js copied to clipboard

Calling getDirectory with undefined should return same dir

Open Sebmaster opened this issue 12 years ago • 2 comments

Not sure if that's intended as-is, but when calling getDirectory with undefined in chrome, chrome calls the callback with the same DirectoryEntry on which getDirectory was called on.

Calling getDirectory with undefined is probably always a bug, in order to be in line with chrome the shim should follow it's behaviour though, not sure which way is better.

Sebmaster avatar May 05 '13 20:05 Sebmaster

Agreed. It should do what the specs says. If the spec doesn't have answers, turn to Chrome's implementation :)

ebidel avatar May 08 '13 04:05 ebidel

I couldn't find any exact specification in the W3C definition.

It says Otherwise, if no other error occurs, getDirectory must return a DirectoryEntrySync corresponding to path. though, not sure if undefined as argument is an error.

Sebmaster avatar May 09 '13 21:05 Sebmaster