Commit b781e97
committed
[TOOL-2764] Dashboard: Fix published contract version selector with duplicate versions (#5893)
<!-- start pr-codex -->
## PR-Codex overview
This PR focuses on refining the contract fetching logic to ensure that only unique published contracts are returned, specifically keeping the latest version of each contract.
### Detailed summary
- Introduced a new variable `publishedContracts` to store fulfilled responses.
- Added logic to filter out duplicate contracts by version, keeping only the latest occurrence.
- Returned the filtered list of unique published contracts.
> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`
<!-- end pr-codex -->1 parent 18ef10b commit b781e97
File tree
1 file changed
+12
-1
lines changed- apps/dashboard/src/components/contract-components
1 file changed
+12
-1
lines changedLines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
51 | 62 | | |
52 | 63 | | |
53 | 64 | | |
| |||
0 commit comments