Skip to content

Commit 9fdd997

Browse files
authored
Update README.md
1 parent 1f2f09a commit 9fdd997

File tree

1 file changed

+3
-2
lines changed
  • not-so-smart-contracts/solana/signer_check

1 file changed

+3
-2
lines changed

not-so-smart-contracts/solana/signer_check/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ fn complete_escrow(_program_id: &Pubkey, accounts: &[AccountInfo], _instruction_
1919
if &state.authority == authority.key {
2020
state.escrow_state = EscrowState::Complete;
2121
state.serialize(&mut &mut **state_info.data.borrow_mut())?;
22+
return Ok(())
2223
}
23-
24-
Ok(())
24+
Err(ProgramError::IncorrectAuthority);
25+
2526
}
2627
```
2728
*Inspired by [SPL Lending Program](https://github.com/solana-labs/solana-program-library/tree/master/token-lending/program)*

0 commit comments

Comments
 (0)