Protocol fee amount is not enforced by staking contract
This commit is contained in:
parent
22e39f782f
commit
9ac715f99d
@ -161,15 +161,8 @@ contract MixinExchangeFees is
|
||||
private
|
||||
view
|
||||
{
|
||||
if (protocolFeePaid == 0) {
|
||||
LibRichErrors.rrevert(
|
||||
LibStakingRichErrors.InvalidProtocolFeePaymentError(
|
||||
LibStakingRichErrors.ProtocolFeePaymentErrorCodes.ZeroProtocolFeePaid,
|
||||
protocolFeePaid,
|
||||
msg.value
|
||||
)
|
||||
);
|
||||
}
|
||||
// The protocol fee must equal the value passed to the contract; unless
|
||||
// the value is zero, in which case the fee is taken in WETH.
|
||||
if (msg.value != protocolFeePaid && msg.value != 0) {
|
||||
LibRichErrors.rrevert(
|
||||
LibStakingRichErrors.InvalidProtocolFeePaymentError(
|
||||
|
@ -30,7 +30,6 @@ library LibStakingRichErrors {
|
||||
}
|
||||
|
||||
enum ProtocolFeePaymentErrorCodes {
|
||||
ZeroProtocolFeePaid,
|
||||
MismatchedFeeAndPayment
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user