Skip to content

Commit

Permalink
add constraint to feed account (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
jdaviderb authored Aug 8, 2022
1 parent 1a0c107 commit 2749a44
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion programs/oracle/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,8 @@ pub struct UpdateOracle<'info> {
#[account(
mut,
constraint = oracle_item.authority == *oracle_authorizer.to_account_info().key,
constraint = chainlink_program.key() == *feed_account.to_account_info().owner
constraint = chainlink_program.key() == *feed_account.to_account_info().owner,
constraint = oracle_item.chainlink_feed == *feed_account.key
)]
oracle_item: Account<'info, OracleItem>,
#[account(mut)]
Expand Down

0 comments on commit 2749a44

Please sign in to comment.