Skip to content

Commit

Permalink
Update constraint to extend delegation
Browse files Browse the repository at this point in the history
  • Loading branch information
ChewingGlass committed Jul 16, 2024
1 parent dceb801 commit d07ceb8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion programs/nft_proxy/src/instructions/assign_proxy_v0.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ pub struct AssignProxyV0<'info> {
bump,
// You can only proxy when it is not currently proxied to someone else.
// Recall the proxy before re-delegating if necessary.
constraint = current_proxy_assignment.next_voter == Pubkey::default()
constraint = current_proxy_assignment.next_voter == Pubkey::default() || current_proxy_assignment.next_voter == voter.key()
)]
pub current_proxy_assignment: Box<Account<'info, ProxyAssignmentV0>>,
/// CHECK: The wallet being delegated to
Expand Down

0 comments on commit d07ceb8

Please sign in to comment.