-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
x/auth: update NewAccountKeeper docs #9020
Conversation
// `maccPerms` is a map of module account to list of permissisons. It's used to construct | ||
// types.PermissionsForAddress and used in keeper.ValidatePermissions. Permissions is a string, | ||
// without any specific structure. It's not use internally by this module (x/auth) but may | ||
// be used by other modules using auth.Keeper to check against configured permissions. | ||
func NewAccountKeeper( | ||
cdc codec.BinaryMarshaler, key sdk.StoreKey, paramstore paramtypes.Subspace, proto func() types.AccountI, | ||
maccPerms map[string][]string, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking to change the maccPerms
type to map[string]types.PermissionsForAddress
, but that would add redundancy when creating the parameters: PermissionsForAddress
repeats the module name (the map key) in it's attributes.
Benchmark finished. See the result: https://github.orijtech.com/benchmark/result?id=2736655a38c040539241d6b7d6da2b68 |
Benchmark beginning. Status page: https://github.orijtech.com/benchmark/status?commit=49a760d940f59d015530ac02f4bea12ed2f770f1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know these are comments, lmk if this is useful
Co-authored-by: Barrie Byron <barrie.byron@tendermint.com>
Benchmark finished. See the result: https://github.orijtech.com/benchmark/result?id=e09a93f9b45f4e499075c63622359d46 |
Benchmark beginning. Status page: https://github.orijtech.com/benchmark/status?commit=78ba066e375a63b962be235fd9747ccf5f42a452 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
@barriebyron , @alessio - thanks for suggestions. |
Description
Updates documentation about
maccPerms
parameter forNewAccountKeeper
Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.
docs/
) or specification (x/<module>/spec/
)godoc
comments.Unreleased
section inCHANGELOG.md
Files changed
in the Github PR explorerCodecov Report
in the comment section below once CI passes