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: remove provider from useEffect dependencies to prevent re-renders
The provider state was being updated inside the effect while also being
included in the dependency array, which could cause unnecessary re-renders
or potential infinite loops. Fixed by using a local newProvider variable
to calculate the correct selected model before updating state.
0 commit comments