difftreelog
Merge pull request #833 from UniqueNetwork/fix/fix-warnings
in: master
3 files changed
pallets/common/src/lib.rsdiffbeforeafterboth500 }500 }501 }501 }502503 impl<T: Config> Pallet<T> {504 /// Helper function that handles deposit events505 pub fn deposit_event(event: Event<T>) {506 let event = <T as Config>::RuntimeEvent::from(event);507 let event = event.into();508 <frame_system::Pallet<T>>::deposit_event(event)509 }510 }502511503 #[pallet::event]512 #[pallet::event]504 #[pallet::generate_deposit(pub fn deposit_event)]505 pub enum Event<T: Config> {513 pub enum Event<T: Config> {506 /// New collection was created514 /// New collection was created507 CollectionCreated(515 CollectionCreated(pallets/evm-contract-helpers/src/lib.rsdiffbeforeafterboth--- a/pallets/evm-contract-helpers/src/lib.rs
+++ b/pallets/evm-contract-helpers/src/lib.rs
@@ -69,7 +69,7 @@
}
#[pallet::pallet]
- #[pallet::generate_store(pub(super) trait Store)]
+ #[pallet::generate_store(trait Store)]
pub struct Pallet<T>(_);
/// Store owner for contract.
@@ -80,9 +80,9 @@
pub(super) type Owner<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = H160, QueryKind = ValueQuery>;
+ /// Deprecated: this storage is deprecated
#[pallet::storage]
- #[deprecated]
- pub(super) type SelfSponsoring<T: Config> =
+ type SelfSponsoring<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = bool, QueryKind = ValueQuery>;
/// Store for contract sponsorship state.
@@ -349,6 +349,7 @@
}
/// Get current sponsoring mode, performing lazy migration from legacy storage
+ /// Deprecated: this method is for deprecated storage
pub fn sponsoring_mode(contract: H160) -> SponsoringModeT {
<SponsoringMode<T>>::get(contract)
.or_else(|| {
@@ -359,6 +360,7 @@
}
/// Reconfigure contract sponsoring mode
+ /// Deprecated: this method is for deprecated storage
pub fn set_sponsoring_mode(contract: H160, mode: SponsoringModeT) {
if mode == SponsoringModeT::Disabled {
<SponsoringMode<T>>::remove(contract);
pallets/unique/src/lib.rsdiffbeforeafterboth--- a/pallets/unique/src/lib.rs
+++ b/pallets/unique/src/lib.rs
@@ -266,10 +266,12 @@
/// * `token_prefix`: Byte string containing the token prefix to mark a collection
/// to which a token belongs (limit [`MAX_TOKEN_PREFIX_LENGTH`]).
/// * `mode`: Type of items stored in the collection and type dependent data.
- // returns collection ID
+ ///
+ /// returns collection ID
+ ///
+ /// Deprecated: `create_collection_ex` is more up-to-date and advanced, prefer it instead.
#[weight = <SelfWeightOf<T>>::create_collection()]
- #[deprecated(note = "`create_collection_ex` is more up-to-date and advanced, prefer it instead")]
- pub fn create_collection(
+ fn create_collection(
origin,
collection_name: BoundedVec<u16, ConstU32<MAX_COLLECTION_NAME_LENGTH>>,
collection_description: BoundedVec<u16, ConstU32<MAX_COLLECTION_DESCRIPTION_LENGTH>>,