Skip to content

fix crashing of app irrespective of aws s3 bucket set up #2610

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

Merged
merged 3 commits into from
Nov 19, 2023

Conversation

PiyushChandra17
Copy link
Contributor

Fixes #2582

Changes:

Made the following changes:

  • Removed response destructuring from error
  • Used optional chaining operator so that in the catch clause if error persists, whole app should not crashed
  • Setting error: error && error.response && error.response.data

I have verified that this pull request:

  • has no linting errors (npm run lint)
  • has no test errors (npm run test)
  • is from a uniquely-named feature branch and is up to date with the develop branch.
  • is descriptively named and links to an issue number, i.e. Fixes #123

Copy link
Collaborator

@lindapaiste lindapaiste left a comment

Choose a reason for hiding this comment

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

Love it! Optional chaining is one of my favorite new JS features. It makes life so much easier.

One tiny request: can you delete the commented-out console.log line?

@PiyushChandra17
Copy link
Contributor Author

@lindapaiste Sure

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.

App is getting crashed in localhost on latest develop
3 participants