fix(web): ignore stale contract list responses #4
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/contract-list-stale-response"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
When the search text or filters change quickly, an older request can finish after a newer one.
Since #3 the late response overwrote the current filter state and the list stayed stuck on the spinner.
The list effect now drops responses that belong to filters that are no longer current
(cleanup flag in
useEffect), so the last search always wins.Testing
npm run lint,npm run buildafter the fix it shows the result of the latest search.