forked from paritytech/polkadot-sdk
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove pallet::getter usage from pallet-contracts-mock-network (parit…
…ytech#4417) A part of paritytech#3326 Removes all #[pallet::getter] usage from the contracts mock network pallet. As the storage values were pub(super), read-only visibility was lost external to the crate upon the removal of the macros. I have implemented custom getters as a replacement, keeping the api the same. If we care very much about consistency of the storagevalue::<T>::get() syntax, the other option would be to set the storage values to pub. Though I find preserving data authority better myself. @muraca
- Loading branch information
1 parent
d803e70
commit 73fab74
Showing
2 changed files
with
23 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Schema: Polkadot SDK PRDoc Schema (prdoc) v1.0.0 | ||
# See doc at https://raw.githubusercontent.com/paritytech/polkadot-sdk/master/prdoc/schema_user.json | ||
|
||
title: Removed `pallet::getter` usage from pallet-contracts-mock-network | ||
|
||
doc: | ||
- audience: Runtime Dev | ||
description: | | ||
This PR removed the `pallet::getter`s from `pallet-contracts-mock-network`s storage items. | ||
|
||
crates: | ||
- name: pallet-contracts-mock-network | ||
bump: minor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters