Skip to content
New issue

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

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

Already on GitHub? # to your account

fix(unpublish): properly apply publishConfig #4601

Merged
merged 1 commit into from
Mar 24, 2022

Commits on Mar 23, 2022

  1. fix(unpublish): properly apply publishConfig

    The tests for unpublish were mocked so heavily they weren't actually
    asserting anything.  In rewriting them several bugs were found.
    
     - `write=true` was not being consistenly used when fetching packument
       data, it is now.
     - The decision on when to load the local package.json file was not
       working at all, that has been fixed.  If the cwd contains a
       package.json whose name matches the package you are uninstalling, the
       local package.json will be read and its publishConfig applied to your
       request.
     - dead code inside the `npm unpublish` path was removed.  There is no
       need to check if you are unpublishing the last version here, you're
       already unpublishing the entire project.
     - publishConfig is now being applied through the config flatten method,
       not a raw object assignment.
    wraithgar committed Mar 23, 2022
    Configuration menu
    Copy the full SHA
    c84d9d8 View commit details
    Browse the repository at this point in the history