Skip to content

Commit feb82f2

Browse files
authored
Merge pull request #68 from solana-developers/token_extension_nft
Added extension nft meta data pointer example
2 parents 4366669 + 944bb7d commit feb82f2

File tree

365 files changed

+52204
-11
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

365 files changed

+52204
-11
lines changed

Cargo.lock

+176-6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

basics/program-derived-addresses/anchor/Anchor.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[features]
22
seeds = false
33
[programs.localnet]
4-
anchor_program_example = "FFKtnYFyzPj1qFjE9epkrfYHJwZMdh8CvJrB6XsKeFVz"
4+
anchor_program_example = "oCCQRZyAbVxujyd8m57MPmDzZDmy2FoKW4ULS7KofCE"
55

66
[registry]
77
url = "https://anchor.projectserum.com"

basics/program-derived-addresses/anchor/programs/anchor-program-example/Cargo.toml

+2-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,5 @@ cpi = ["no-entrypoint"]
1616
default = []
1717

1818
[dependencies]
19-
anchor-lang = "0.28.0"
19+
anchor-lang = "0.29.0"
20+
ahash = "=0.8.6"

basics/program-derived-addresses/anchor/programs/anchor-program-example/src/instructions/create.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ pub struct CreatePageVisits<'info> {
2323
pub fn create_page_visits(ctx: Context<CreatePageVisits>) -> Result<()> {
2424
*ctx.accounts.page_visits = PageVisits {
2525
page_visits: 0,
26-
bump: *ctx.bumps.get("page_visits").unwrap(),
26+
bump: ctx.bumps.page_visits,
2727
};
2828

2929
Ok(())

basics/program-derived-addresses/anchor/programs/anchor-program-example/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use instructions::*;
77
pub mod instructions;
88
pub mod state;
99

10-
declare_id!("FFKtnYFyzPj1qFjE9epkrfYHJwZMdh8CvJrB6XsKeFVz");
10+
declare_id!("oCCQRZyAbVxujyd8m57MPmDzZDmy2FoKW4ULS7KofCE");
1111

1212
#[program]
1313
pub mod anchor_program_example {

basics/program-derived-addresses/anchor/programs/anchor-program-example/src/state/page_visits.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ pub struct PageVisits {
88
}
99

1010
impl PageVisits {
11-
pub const SEED_PREFIX: &[u8; 11] = b"page_visits";
11+
pub const SEED_PREFIX: &'static [u8; 11] = b"page_visits";
1212

1313
pub fn increment(&mut self) {
1414
self.page_visits = self.page_visits.checked_add(1).unwrap();

0 commit comments

Comments
 (0)