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

aws-node-fetch-file-and-store-in-s3: improve error message #126

Merged

Conversation

christophgysin
Copy link
Contributor

No description provided.

return response;
}
return Promise.reject(new Error(
`Failed to fetch ${event.image_url}: ${response.status} ${response.statusText}`));
Copy link
Contributor

Choose a reason for hiding this comment

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

Isn't it best to pull the URL from the response object? Just to make the code a bit more copy & pastable ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

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.

2 participants