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: Safely parse announcement Flag #3052

Merged
merged 1 commit into from
Nov 28, 2023
Merged

Conversation

kyle-ssg
Copy link
Member

Thanks for submitting a PR! Please check the boxes below:

  • I have run pre-commit to check linting
  • I have filled in the "Changes" section below?
  • I have filled in the "How did you test this code" section below?
  • I have used a Conventional Commit title for this Pull Request

Changes

Instead of trying to JSON parse a feature flag without catching, the frontend will now safely handle the non-json type by providing a fallback.

Please describe.

How did you test this code?

Tried with / without a null, json and undefined announcement as well as dismissing the announcement.

Please describe.

Copy link

vercel bot commented Nov 28, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 28, 2023 9:15am
flagsmith-frontend-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 28, 2023 9:15am
flagsmith-frontend-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 28, 2023 9:15am

Copy link
Contributor

github-actions bot commented Nov 28, 2023

Uffizzi Preview deployment-41603 was deleted.

@kyle-ssg kyle-ssg changed the title Safely parse announcement Flag fix: Safely parse announcement Flag Nov 28, 2023
@matthewelwell matthewelwell added this pull request to the merge queue Nov 28, 2023
Merged via the queue into main with commit 6994f6b Nov 28, 2023
@matthewelwell matthewelwell deleted the fix/announcement-parsing branch November 28, 2023 09:46
Copy link

sentry-io bot commented Nov 30, 2023

Suspect Issues

This pull request was deployed and Sentry observed the following issues:

  • ‼️ TypeError: null is not an object (evaluating 'window.localStorage.setItem') _class.render(web/components/App) View Issue
  • ‼️ TypeError: null is not an object (evaluating 'window.localStorage.setItem') _class.render(web/components/App) View Issue

Did you find this useful? React with a 👍 or 👎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
front-end Issue related to the React Front End Dashboard
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants