From 62800e37221896f272b85d3fedd157dbff3a395b Mon Sep 17 00:00:00 2001 From: PraetorP Date: Thu, 15 Dec 2022 08:36:32 +0000 Subject: [PATCH] refactor: unused method has been deleted, added doc for `setCollectionLimit`. --- --- a/pallets/common/src/erc.rs +++ b/pallets/common/src/erc.rs @@ -412,6 +412,7 @@ /// "ownerCanTransfer", /// "ownerCanDestroy", /// "transfersEnabled" + /// @param status enable\disable limit. Works only with `true`. /// @param value Value of the limit. #[solidity(rename_selector = "setCollectionLimit")] fn set_collection_limit( @@ -883,32 +884,4 @@ )) }) } -} - -fn convert_value_limit + Copy>( - limit: EvmCollectionLimits, - value: &Option, -) -> (EvmCollectionLimits, bool, uint256) { - value - .map(|v| (limit, true, v.into())) - .unwrap_or((limit, false, Default::default())) -} - -fn convert_bool_limit( - limit: EvmCollectionLimits, - value: &Option, -) -> (EvmCollectionLimits, bool, uint256) { - value - .map(|v| { - ( - limit, - true, - if v { - uint256::from(1) - } else { - Default::default() - }, - ) - }) - .unwrap_or((limit, false, Default::default())) } -- gitstuff