From 5b3419a264d760cfa52a12aa5fee0b5456811b49 Mon Sep 17 00:00:00 2001 From: nikitosing <32202610+nikitosing@users.noreply.github.com> Date: Thu, 29 Feb 2024 10:05:45 +0300 Subject: [PATCH] Fix no function clause matching in Integer.parse/2 (#9484) * Fix no function clause matching in Integer.parse/2 * Changelog --- CHANGELOG.md | 1 + apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/contract.ex | 10 +++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1ac9998300f6..f90e4ed2784f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ - [#9502](https://github.com/blockscout/blockscout/pull/9502) - Add batch_size and concurrency envs for tt token type migration - [#9493](https://github.com/blockscout/blockscout/pull/9493) - Fix API response for unknown blob hashes +- [#9484](https://github.com/blockscout/blockscout/pull/9484) - Fix read contract error - [#9426](https://github.com/blockscout/blockscout/pull/9426) - Fix tabs counter cache bug ### Chore diff --git a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/contract.ex b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/contract.ex index 729b218200ae..64ed49911d59 100644 --- a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/contract.ex +++ b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/contract.ex @@ -133,9 +133,13 @@ defmodule EthereumJSONRPC.Contract do defp convert_int_string_to_array_inner(arg) do arg - |> Enum.map(fn el -> - {int, _} = Integer.parse(el) - int + |> Enum.map(fn + el when is_integer(el) -> + el + + el -> + {int, _} = Integer.parse(el) + int end) end