-
Notifications
You must be signed in to change notification settings - Fork 123
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
Clean up extrinsic params builder #405
Conversation
9547293
to
73c0fd5
Compare
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, just a few nitpicky suggestions.
Regarding Polkadot
vs SubstrateDefault
I don't have a strong opinion. I think I would leave it as is for now.
Nice looks in general good great that you noticed that we can remove the specific builder definitions! I have a few remarks about the terminology:
So from my point of view we can either name it: |
Renamed to Generic - I think that fits the purpose. Thanks for the input :) |
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
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.
Thanks for fixing the naming! Looks good to me!
Changes the following:
AssetTipExtrinsicParamsBuilder
andPlainTipExtrinsicParamsBuilder
. They are simply unnecessary and cause confusion. The api already sets the needed types (Tip, Index and Hash).ExtrinsicParamsBuilder
toAdditionalParams
. Reasoning: the name "Builder" suggests that it builds "ExtrinsicParams", but it does not. It only ever built theOtherParams
. But a builder seems a little over the top anyway. So a simple...AdditionalParams
should do it.Base
orDefault
toGeneric
because they are compatible with most substrate / polkadot nodes and are generic over Tip and Hash.Base
did not fit IMO because that implicates that it is extensible. But it is not. One would need to redefine the Params in case something is changed on the node side.closes #400