Skip to content
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

feat: Move sponsorship from frontier #911

Closed
wants to merge 3 commits into from

Conversation

bugrazoid
Copy link
Contributor

No description provided.

@@ -121,3 +162,137 @@ where
}
}
}

/// Bla bla bla Mr. Freeman
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Видимо не хватает коммента.

// #[cfg(feature = "debug-logging")]
// log::trace!(target: "sponsoring", "checking who will pay fee for {:?} {:?}", source, reason);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Это надо либо раскоментить либо удалить.

origin: &T::CrossAccountId,
) -> Result<CheckEvmTransaction<'a, E>, E> {
let who = &v.who;
let max_fee_per_gas = Some(v.transaction_fee_input()?.0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Может лучше не оборачивать в Option, чтобы потом не делать unwrap?
И оставить let (max_fee_per_gas, _) = self.transaction_fee_input()?; как было.

)
.as_ref()
.map(pallet_evm::Pallet::<T>::account_basic_by_id)
.map(|v| v.0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Дело вкуса, но мне больше нравится .map(|(v, _)| v);

.map(|v| v.0);

let fee = max_fee_per_gas.unwrap().saturating_mul(v.transaction.gas_limit);
if let Some(sponsor) = sponsor.as_ref() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Проверка if self.config.is_transactional || fee > U256::zero() {, которая есть в изначальном коде, здесь не нужна?

@bugrazoid bugrazoid force-pushed the feature/move_sponsorship_to_chain branch from f0a75e4 to 02ae332 Compare May 17, 2023 05:22
@fairax fairax force-pushed the feature/move_sponsorship_to_chain branch from 02ae332 to 84ba084 Compare July 18, 2023 11:47
@fairax fairax changed the base branch from develop to feature/update-polkadot-v0.9.43 July 18, 2023 11:48
@fairax fairax force-pushed the feature/move_sponsorship_to_chain branch from 84ba084 to 257fe16 Compare July 18, 2023 11:49
@uandysmith uandysmith marked this pull request as ready for review July 19, 2023 08:12
Base automatically changed from feature/update-polkadot-v0.9.43 to develop August 14, 2023 13:11
@fairax fairax force-pushed the feature/move_sponsorship_to_chain branch from 257fe16 to 1613a8e Compare September 7, 2023 17:56
@fairax fairax force-pushed the feature/move_sponsorship_to_chain branch from 1613a8e to 4c3b709 Compare September 7, 2023 21:12
@fairax fairax force-pushed the feature/move_sponsorship_to_chain branch from 4c3b709 to 78ef2a9 Compare September 7, 2023 21:26
@CertainLach CertainLach closed this Oct 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants