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

Fix confusing XOR operator when exponentiation was meant #664

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
4 changes: 2 additions & 2 deletions content/courses/onchain-development/anchor-cpi.md
Original file line number Diff line number Diff line change
Expand Up @@ -575,7 +575,7 @@ pub fn add_movie_review(
&[ctx.bumps.mint]
]]
),
10*10^6
10 * 10u64.pow(6)
)?;

msg!("Minted tokens");
Expand Down Expand Up @@ -705,7 +705,7 @@ it("Movie review is added`", async () => {
);

const userAta = await getAccount(provider.connection, tokenAccount);
expect(Number(userAta.amount)).to.equal((10 * 10) ^ 6);
expect(Number(userAta.amount)).to.equal(10 * Math.pow(10, 6));
});
```

Expand Down
Loading