fix(governance): corrected sorting of upgrade proposals by blockheight (#4729)

This commit is contained in:
Sam Keen 2023-09-08 10:19:59 +01:00 committed by GitHub
parent 08e204fe31
commit 45623f33c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -55,7 +55,10 @@ export const orderByUpgradeBlockHeight = (
) =>
orderBy(
arr,
[(p) => p?.upgradeBlockHeight, (p) => p.vegaReleaseTag],
[
(p) => (p?.upgradeBlockHeight ? parseInt(p.upgradeBlockHeight, 10) : 0),
(p) => p.vegaReleaseTag,
],
['desc', 'desc']
);