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: do not pack rejections from resolve in array #88

Merged
merged 2 commits into from Oct 15, 2020

Conversation

raphinesse
Copy link
Contributor

Motivation and Context

We use the package resolve to find out if a requested dependency is already installed. That package exports a callback based async API that we promisify using pify. Since the callback of resolve is called with multiple result arguments, we need to use the multiArgs option of pify here. Unfortunately that also wraps the errors of resolve into an array.

Description

This PR unwraps the errors returned by our promisified resolve.

Testing

Manual

@codecov-io
Copy link

codecov-io commented Oct 15, 2020

Codecov Report

Merging #88 into master will increase coverage by 0.12%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #88      +/-   ##
==========================================
+ Coverage   92.18%   92.30%   +0.12%     
==========================================
  Files           1        1              
  Lines          64       65       +1     
==========================================
+ Hits           59       60       +1     
  Misses          5        5              
Impacted Files Coverage Δ
index.js 92.30% <100.00%> (+0.12%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c19f888...57bdd23. Read the comment docs.

@raphinesse raphinesse added this to the 3.0.1 milestone Oct 15, 2020
Copy link
Member

@timbru31 timbru31 left a comment

Choose a reason for hiding this comment

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

LGTM

@raphinesse raphinesse merged commit 8dc1fe1 into apache:master Oct 15, 2020
@raphinesse raphinesse deleted the fix-resolve-errors branch October 15, 2020 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants