Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small typos in anchor-cpi.md leading to failing tests #635

Merged
merged 2 commits into from
Nov 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions content/courses/onchain-development/anchor-cpi.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ The `cpi` module turns `callee`'s instruction handlers into Rust functions.
These functions take a `CpiContext` and any extra data needed for the
instruction. They work just like the instruction handlers in your Anchor
programs, but use `CpiContext` instead of `Context`. The `cpi` module also
provides the account structs needed for these instruction handler.
provides the account structs needed for these instruction handlers.

For example, if `callee` has the instruction `do_something` that requires the
accounts defined in the `DoSomething` struct, you could invoke `do_something` as
Expand Down Expand Up @@ -383,7 +383,7 @@ pub struct InitializeMint<'info> {
bump,
payer = user,
mint::decimals = 6,
mint::authority = mint,
mint::authority = user,
)]
pub mint: Account<'info, Mint>,
#[account(mut)]
Expand Down Expand Up @@ -661,7 +661,7 @@ it("Initializes the reward token", async () => {
});
```

Notice that we didn't have to add `.accounts` because they call be inferred,
Notice that we didn't have to add `.accounts` because they can be inferred,
including the `mint` account (assuming you have seed inference enabled).

Next, update the test for the `addMovieReview` instruction. The primary
Expand Down