Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Fix] resolution when filename option is passed #167

Merged
merged 1 commit into from
Jun 17, 2018
Merged

Conversation

goto-bus-stop
Copy link
Member

PR #162 introduced a parent variable that contains either the full
filename of the requiring module or the basedir. Some of the places
where basedir was used were updated to use parent instead, but
that's not correct; the path.resolve() calls would receive the full
filename instead of the directory name.

This patch reverts the improper parent uses to basedir.

PR #162 introduced a `parent` variable that contains either the full
filename of the requiring module or the `basedir`. Some of the places
where `basedir` was used were updated to use `parent` instead, but
that's not correct; the `path.resolve()` calls would receive the full
filename instead of the directory name.

This patch reverts the improper `parent` uses to `basedir`.
Copy link
Member

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, appreciate the test cases!

@ljharb ljharb merged commit 29495fb into master Jun 17, 2018
@ljharb ljharb deleted the fix-filename-opt branch June 17, 2018 16:25
ljharb added a commit that referenced this pull request Jun 17, 2018
 - [Fix] resolution when `filename` option is passed (#167, #162)
 - [Docs] clean up readme code
 - [Tests] improve output of symlink tests that fail on Mac
 - [Tests] up to `node` `v10.4`
ljharb added a commit that referenced this pull request Jun 17, 2018
v1.8.1

 - [Fix] resolution when `filename` option is passed (#167, #162)
 - [Docs] clean up readme code
 - [Tests] improve output of symlink tests that fail on Mac
 - [Tests] up to `node` `v10.4`
@ljharb
Copy link
Member

ljharb commented Jun 17, 2018

Released in v1.8.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants