You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(useBattery): handle unmount cleanup and promise rejection
- Add mounted flag to prevent state updates after unmount
- Prevent event listener registration if component unmounts before
getBattery() resolves
- Add .catch() handler to gracefully handle promise rejections
- Fix misleading comment for fetched field
0 commit comments