-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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: Ensure gauges not undefined or empty object and gauges fixes #10944
base: develop
Are you sure you want to change the base?
fix: Ensure gauges not undefined or empty object and gauges fixes #10944
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
6 Skipped Deployments
|
|
|
||
return gauges | ||
} | ||
return [] as Gauge[] | ||
throw Error('Failed to fetch gauges') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to retry if it fails
b672a08
to
15ecaa7
Compare
7f12618
to
99944fb
Compare
Fixes search query removed when account connect
Fixes discrepancy between search query and list
Fixes undefined or empty gauges causes percent object constructor error
Memoize callbacks to reduce rerenders on client side
PR-Codex overview
This PR focuses on improving the code quality and functionality of various components in the
GaugesVoting
andSearchInput
modules. It includes enhancements like better handling of optional values, use of callbacks, and improved state management.Detailed summary
maxCapPercent
to handle undefined values indata?.maxVoteCap
.useUrlQueryGauge
for cleaner syntax.useGauges
.SearchInput
with auseCallback
foronChange
.FilterFieldInput
to use auseCallback
for handling changes.sortedData
returns an empty array if no data is present.useCallback
forhandleSort
andhandleOnCollapse
inGaugesTable
.