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: throw error instead of string #9284

Merged
merged 1 commit into from
Oct 22, 2018
Merged

fix: throw error instead of string #9284

merged 1 commit into from
Oct 22, 2018

Conversation

justsml
Copy link
Contributor

@justsml justsml commented Oct 21, 2018

Fixes #9283

Description

This is a minor issue around error visibility.

Here's how Bluebird's warning about the issue shows up:

image

Warning: a promise was rejected with a non-error: [object String]

To fix this, rej(string) must be called with a new Error(string) instead.

@pieh pieh changed the title Promise issue from #9283 fix: throw error instead of string Oct 22, 2018
Copy link
Contributor

@pieh pieh left a comment

Choose a reason for hiding this comment

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

Thanks @justsml!

@pieh pieh merged commit bcdd834 into gatsbyjs:master Oct 22, 2018
@gatsbot
Copy link

gatsbot bot commented Oct 22, 2018

Holy buckets, @justsml — we just merged your PR to Gatsby! 💪💜

Gatsby is built by awesome people like you. Let us say “thanks” in two ways:

  1. We’d like to send you some Gatsby swag. As a token of our appreciation, you can go to the Gatsby Swag Store and log in with your GitHub account to get a coupon code good for one free piece of swag. (Currently we’ve got a couple t-shirts available, plus some socks that are really razzing our berries right now.)
  2. We just invited you to join the Gatsby organization on GitHub. This will add you to our team of maintainers. Accept the invite by visiting https://github.com/orgs/gatsbyjs/invitation. By joining the team, you’ll be able to label issues, review pull requests, and merge approved pull requests.

If there’s anything we can do to help, please don’t hesitate to reach out to us: tweet at @gatsbyjs and we’ll come a-runnin’.

Thanks again!

@justsml justsml deleted the patch-1 branch October 23, 2018 15:41
jedrichards pushed a commit to jedrichards/gatsby that referenced this pull request Nov 1, 2018
Fixes gatsbyjs#9283

## Description

This is a minor issue around error visibility.

Here's how Bluebird's warning about the issue shows up:

![image](https://user-images.githubusercontent.com/397632/47270777-d47ce680-d52d-11e8-9a1d-1812a9837d5a.png)

`Warning: a promise was rejected with a non-error: [object String]`

To fix this, `rej(string)` must be called with a `new Error(string)` instead.
gpetrioli pushed a commit to gpetrioli/gatsby that referenced this pull request Jan 22, 2019
Fixes gatsbyjs#9283

## Description

This is a minor issue around error visibility.

Here's how Bluebird's warning about the issue shows up:

![image](https://user-images.githubusercontent.com/397632/47270777-d47ce680-d52d-11e8-9a1d-1812a9837d5a.png)

`Warning: a promise was rejected with a non-error: [object String]`

To fix this, `rej(string)` must be called with a `new Error(string)` instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error in Wordpress Queue Loses Stack Trace
2 participants