Skip to content

Commit

Permalink
docs: add explanation on why not need to filter challenged in/output
Browse files Browse the repository at this point in the history
  • Loading branch information
boolafish committed Feb 17, 2020
1 parent 5dbe305 commit 15dffd9
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,8 @@ library PaymentProcessInFlightExit {
{
for (uint16 i = 0; i < PaymentTransactionModel.MAX_INPUT_NUM(); i++) {
PaymentExitDataModel.WithdrawData memory withdrawal = exit.inputs[i];

// challenged input would remove the piggyback flag
if (token == withdrawal.token && exit.isInputPiggybacked(i)) {
bool success = SafeEthTransfer.transferReturnResult(
withdrawal.exitTarget, withdrawal.piggybackBondSize, self.safeGasStipend
Expand All @@ -278,6 +280,8 @@ library PaymentProcessInFlightExit {
{
for (uint16 i = 0; i < PaymentTransactionModel.MAX_OUTPUT_NUM(); i++) {
PaymentExitDataModel.WithdrawData memory withdrawal = exit.outputs[i];

// challenged output would remove the piggyback flag
if (token == withdrawal.token && exit.isOutputPiggybacked(i)) {
bool success = SafeEthTransfer.transferReturnResult(
withdrawal.exitTarget, withdrawal.piggybackBondSize, self.safeGasStipend
Expand Down

0 comments on commit 15dffd9

Please sign in to comment.