Skip to content

Commit

Permalink
Account for stake de-registration in account_info for vote delegation
Browse files Browse the repository at this point in the history
  • Loading branch information
Scitz0 committed Nov 2, 2024
1 parent f748792 commit 4b9eabd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions files/grest/rpc/account/account_info.sql
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,11 @@ BEGIN
FROM delegation_vote AS dv1
WHERE dv1.addr_id = dv.addr_id
AND dv1.id > dv.id)
AND NOT EXISTS (
SELECT TRUE
FROM stake_deregistration
WHERE stake_deregistration.addr_id = dv.addr_id
AND stake_deregistration.tx_id > dv.tx_id)
) AS vote_t ON vote_t.addr_id = status_t.id
LEFT JOIN (
SELECT
Expand Down

0 comments on commit 4b9eabd

Please sign in to comment.