Skip to content

Commit

Permalink
Fix actionable navigation between voting and getting new proposals (#…
Browse files Browse the repository at this point in the history
…4741)

# Motivation

When the user clicks 'next' or 'prev' to navigate through proposals
while voting, there is a chance (especially on slow network) that the
dapp may break, because after successful voting the actionables are
removed and the new data could be not retrieved yet.

# Changes

- check that `proposalIds` exists before rendering the
`ProposalNavigation`

# Tests

It's possible to reproduce the issue locally, so the fix was also tested
locally.

# Todos

- [ ] Add entry to changelog (if necessary).
Not necessary since the feature is not publicly available
  • Loading branch information
mstrasinskis authored Apr 18, 2024
1 parent 3b9f150 commit 1abbfbf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
</script>

<TestIdWrapper testId="nns-proposal-component">
{#if $store?.proposal?.id !== undefined}
{#if $store?.proposal?.id !== undefined && nonNullish(proposalIds)}
{#if $referrerPathStore !== AppPath.Launchpad}
<ProposalNavigation
title={proposalType}
Expand Down

0 comments on commit 1abbfbf

Please sign in to comment.