Skip to content
This repository was archived by the owner on Mar 4, 2026. It is now read-only.

Remove unhandled Promise rejection warning#556

Merged
schmidt-sebastian merged 2 commits intomasterfrom
mrschmidt-unhandled
Feb 26, 2019
Merged

Remove unhandled Promise rejection warning#556
schmidt-sebastian merged 2 commits intomasterfrom
mrschmidt-unhandled

Conversation

@schmidt-sebastian
Copy link
Copy Markdown
Contributor

In #553, I added type information to DeferredPromise. As part of this, I changed the initialization in the constructor to Promise.reject() since I no longer know the value type. Turns out that that logs a bunch of "unhandled promise rejection" warnings. This PR makes the Promise nullable and defers the initialization. It's not the cleanest solution, but it's test-only code that isn't reused...

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Feb 25, 2019
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 25, 2019

Codecov Report

Merging #556 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #556   +/-   ##
=======================================
  Coverage   95.85%   95.85%           
=======================================
  Files          24       24           
  Lines        1931     1931           
  Branches      168      168           
=======================================
  Hits         1851     1851           
  Misses         57       57           
  Partials       23       23

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 a78495b...7a492ff. Read the comment docs.

Copy link
Copy Markdown
Contributor

@mikelehen mikelehen left a comment

Choose a reason for hiding this comment

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

OK

@schmidt-sebastian schmidt-sebastian merged commit 82eb2cf into master Feb 26, 2019
@schmidt-sebastian schmidt-sebastian deleted the mrschmidt-unhandled branch March 11, 2019 03:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants