gulpjs / vinyl

Virtual file format.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Normalize paths upon construction without stat object

phated opened this issue · comments

As I brought up in @darsain's PR, I'm not sure we should normalize the history of an object upon construction if no stat object is passed. If the history represents a directory but no stat object is passed, will the paths be normalized incorrectly?

I'd like to get some feedback on this.

Actually, I don't think isDirectory or isSymbolic is used at all in normalization. Always normalizing should be fine.

If the history represents a directory but no stat object is passed, will the paths be normalized incorrectly?

That was the case when we were going with directories always ending in a separator. Since that got dropped, all paths are now going to look consistently the same.

Just search the index.js for isDirectory or isSymbolic and you'll see that there is no code dependent on them, so there is really no need for this issue :)

@darsain yeah, I was noticing that. I think the change just needs to be in the docs. Thanks for following up.