difftreelog
Small fixes
in: master
2 files changed
pallets/nft/src/lib.rsdiffbeforeafterboth942 #[transactional]942 #[transactional]943 pub fn set_transfers_enabled_flag(origin, collection_id: CollectionId, value: bool) -> DispatchResult {943 pub fn set_transfers_enabled_flag(origin, collection_id: CollectionId, value: bool) -> DispatchResult {944944945 let sender = T::CrossAccountId::from_sub(ensure_signed(origin)?);945 let sender = ensure_signed(origin)?;946 let mut target_collection = Self::get_collection(collection_id)?;946 let mut target_collection = Self::get_collection(collection_id)?;947947948 Self::check_owner_permissions(&target_collection, sender.as_sub())?;948 Self::check_owner_permissions(&target_collection, &sender)?;949 949 950 target_collection.transfers_enabled = value;950 target_collection.transfers_enabled = value;951 Self::save_collection(target_collection);951 Self::save_collection(target_collection);pallets/nft/src/mock.rsdiffbeforeafterboth--- a/pallets/nft/src/mock.rs
+++ b/pallets/nft/src/mock.rs
@@ -102,41 +102,6 @@
type Timestamp = pallet_timestamp::Pallet<Test>;
type Randomness = pallet_randomness_collective_flip::Pallet<Test>;
-// parameter_types! {
-// pub const TombstoneDeposit: u64 = 1;
-// pub const DepositPerContract: u64 = 1;
-// pub const DepositPerStorageByte: u64 = 1;
-// pub const DepositPerStorageItem: u64 = 1;
-// pub RentFraction: Perbill = Perbill::from_rational(1u32, 30 * 24 * 60 * 10);
-// pub const SurchargeReward: u64 = 1;
-// pub const SignedClaimHandicap: u32 = 2;
-// pub DeletionWeightLimit: u64 = u64::MAX;//Perbill::from_percent(10);
-// pub DeletionQueueDepth: u32 = 10;
-// pub Schedule: pallet_contracts::Schedule<Test> = Default::default();
-// }
-
-// impl pallet_contracts::Config for Test {
-// type Time = Timestamp;
-// type Randomness = Randomness;
-// type Currency = pallet_balances::Pallet<Test>;
-// type Event = ();
-// type RentPayment = ();
-// type SignedClaimHandicap = SignedClaimHandicap;
-// type TombstoneDeposit = TombstoneDeposit;
-// type DepositPerContract = DepositPerContract;
-// type DepositPerStorageByte = DepositPerStorageByte;
-// type DepositPerStorageItem = DepositPerStorageItem;
-// type RentFraction = RentFraction;
-// type SurchargeReward = SurchargeReward;
-// type DeletionWeightLimit = DeletionWeightLimit;
-// type DeletionQueueDepth = DeletionQueueDepth;
-// type ChainExtension = ();
-// type WeightPrice = ();
-// type WeightInfo = pallet_contracts::weights::SubstrateWeight<Self>;
-// type Schedule = Schedule;
-// type CallStack = [pallet_contracts::Frame<Self>; 31];
-// }
-
parameter_types! {
pub const CollectionCreationPrice: u32 = 0;
pub TreasuryAccountId: u64 = 1234;