Skip to content

Commit

Permalink
remove debug logging (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
galxy25 authored Dec 5, 2023
1 parent de558c4 commit 9b81a61
Showing 1 changed file with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
diff --git a/apps/explorer/lib/explorer/chain/internal_transaction.ex b/apps/explorer/lib/explorer/chain/internal_transaction.ex
index c86bfa699f..1b2d0cbac6 100644
index c86bfa699f..0a08f3a1b2 100644
--- a/apps/explorer/lib/explorer/chain/internal_transaction.ex
+++ b/apps/explorer/lib/explorer/chain/internal_transaction.ex
@@ -3,6 +3,8 @@ defmodule Explorer.Chain.InternalTransaction do

use Explorer.Schema

+ require Logger
+
alias Explorer.Chain.{Address, Block, Data, Gas, Hash, PendingBlockOperation, Transaction, Wei}
alias Explorer.Chain.InternalTransaction.{Action, CallType, Result, Type}
@@ -502,7 +504,16 @@ defmodule Explorer.Chain.InternalTransaction do

@@ -502,7 +504,15 @@ defmodule Explorer.Chain.InternalTransaction do
# Validates that :call `type` changeset either has an `error` or both `gas_used` and `output`
defp validate_call_error_or_result(changeset) do
case get_field(changeset, :error) do
- nil -> validate_required(changeset, [:gas_used, :output], message: "can't be blank for successful call")
+ nil ->
+ if get_field(changeset, :gas_used) == nil && get_field(changeset, :output) == nil do
+ changeset |>
+ IO.inspect() |>
+ Ecto.Changeset.change(
+ error: "execution reverted"
+ )
Expand Down

0 comments on commit 9b81a61

Please sign in to comment.