mpl_bubblegum/
utils.rs

1use solana_program::pubkey::Pubkey;
2
3/// Computes the asset id of an asset given its tree and nonce values.
4pub fn get_asset_id(tree: &Pubkey, nonce: u64) -> Pubkey {
5    Pubkey::find_program_address(&[b"asset", tree.as_ref(), &nonce.to_le_bytes()], &crate::ID).0
6}