In function normalize (l33) when parameters are for instance:
name: "./some-file"
baseName: "../../vendor/some-lib/"
When analyzing the path, it enters the if (l67) because the baseName was starting with "../..". Then it breaks and never remove the "./" from the path.
In the end, the named module identified as "../../vendor/some-lib/some-file" will never get loaded because the dependency required will be "../../vendor/some-lib/./some-file".
I would be happy to submit a merge request but I before that I would like to understand what this "if" tries to solve in the first place and I don't really understand the comment below. Does somebody as any hint about that ?
In function normalize (l33) when parameters are for instance: name: "./some-file" baseName: "../../vendor/some-lib/"
When analyzing the path, it enters the if (l67) because the baseName was starting with "../..". Then it breaks and never remove the "./" from the path. In the end, the named module identified as "../../vendor/some-lib/some-file" will never get loaded because the dependency required will be "../../vendor/some-lib/./some-file".
I would be happy to submit a merge request but I before that I would like to understand what this "if" tries to solve in the first place and I don't really understand the comment below. Does somebody as any hint about that ?