difftreelog
NextCollectionId renamed
in: master
1 file changed
pallets/nft/src/lib.rsdiffbeforeafterboth131 trait Store for Module<T: Trait> as Nft {131 trait Store for Module<T: Trait> as Nft {132132133 // Private members133 // Private members134 NextCollectionID: u64;134 CreatedCollectionCount: u64;135 ItemListIndex: map hasher(blake2_128_concat) u64 => u64;135 ItemListIndex: map hasher(blake2_128_concat) u64 => u64;136136137 pub Collection get(fn collection): map hasher(identity) u64 => CollectionType<T::AccountId>;137 pub Collection get(fn collection): map hasher(identity) u64 => CollectionType<T::AccountId>;212 ensure!(prefix.len() <= 16, "Token prefix can not be longer than 15 char");212 ensure!(prefix.len() <= 16, "Token prefix can not be longer than 15 char");213213214 // Generate next collection ID214 // Generate next collection ID215 let next_id = NextCollectionID::get()215 let next_id = CreatedCollectionCount::get()216 .checked_add(1)216 .checked_add(1)217 .expect("collection id error");217 .expect("collection id error");218218219 NextCollectionID::put(next_id);219 CreatedCollectionCount::put(next_id);220220221 // Create new collection221 // Create new collection222 let new_collection = CollectionType {222 let new_collection = CollectionType {