difftreelog
refactor unused method has been deleted, added doc for `setCollectionLimit`.
in: master
1 file changed
pallets/common/src/erc.rsdiffbeforeafterboth412 /// "ownerCanTransfer",412 /// "ownerCanTransfer",413 /// "ownerCanDestroy",413 /// "ownerCanDestroy",414 /// "transfersEnabled"414 /// "transfersEnabled"415 /// @param status enable\disable limit. Works only with `true`.415 /// @param value Value of the limit.416 /// @param value Value of the limit.416 #[solidity(rename_selector = "setCollectionLimit")]417 #[solidity(rename_selector = "setCollectionLimit")]417 fn set_collection_limit(418 fn set_collection_limit(885 }886 }886}887}887888fn convert_value_limit<V: Into<uint256> + Copy>(889 limit: EvmCollectionLimits,890 value: &Option<V>,891) -> (EvmCollectionLimits, bool, uint256) {892 value893 .map(|v| (limit, true, v.into()))894 .unwrap_or((limit, false, Default::default()))895}896897fn convert_bool_limit(898 limit: EvmCollectionLimits,899 value: &Option<bool>,900) -> (EvmCollectionLimits, bool, uint256) {901 value902 .map(|v| {903 (904 limit,905 true,906 if v {907 uint256::from(1)908 } else {909 Default::default()910 },911 )912 })913 .unwrap_or((limit, false, Default::default()))914}915888