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

Added timeout and return null for errors #5

Merged
merged 1 commit into from
Jun 1, 2020
Merged

Added timeout and return null for errors #5

merged 1 commit into from
Jun 1, 2020

Conversation

longzheng
Copy link
Contributor

@longzheng longzheng commented May 31, 2020

  • Added a timeout for 2 seconds, otherwise I think axios has default timeout of 0 (infinite)
  • Added a return null for any HTTP errors, otherwise doesn't return promise

@Stog Stog merged commit b5152fa into Stog:master Jun 1, 2020
@longzheng longzheng deleted the patch-1 branch June 1, 2020 09:49
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