Skip to content

Commit

Permalink
lang: Fix incorrectly checking the first init constraint (coral-xyz#2483
Browse files Browse the repository at this point in the history
)
  • Loading branch information
CanardMandarin authored May 7, 2023
1 parent ac86e15 commit d1ddf00
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lang/syn/src/parser/accounts/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ fn constraints_cross_checks(fields: &[AccountField]) -> ParseResult<()> {
));
}
}
match kind {
match &field.constraints.init.as_ref().unwrap().kind {
// This doesn't catch cases like account.key() or account.key.
// My guess is that doesn't happen often and we can revisit
// this if I'm wrong.
Expand Down

0 comments on commit d1ddf00

Please sign in to comment.