Process reviewer comments

pull/9189/head
Viktor Baranov 10 months ago
parent 501cf89338
commit afe801dfc2
  1. 5
      CHANGELOG.md
  2. 8
      apps/explorer/lib/explorer/chain/search.ex
  3. 6
      apps/explorer/lib/explorer/chain/user_operation.ex

@ -8,11 +8,6 @@
- [#9169](https://github.com/blockscout/blockscout/pull/9169) - Add bridged tokens functionality to master branch
- [#9158](https://github.com/blockscout/blockscout/pull/9158) - Increase shared memory for PostgreSQL containers
- [#9155](https://github.com/blockscout/blockscout/pull/9155) - Allow bypassing avg block time in proxy implementation re-fetch ttl calculation
- [#9145](https://github.com/blockscout/blockscout/pull/9145) - Proxy for Account abstraction microservice
- [#9131](https://github.com/blockscout/blockscout/pull/9131) - Merge addresses stage with address referencing
- [#9072](https://github.com/blockscout/blockscout/pull/9072) - Add tracing by block logic for geth
- [#9056](https://github.com/blockscout/blockscout/pull/9056) - Noves.fi API proxy
- [#9155](https://github.com/blockscout/blockscout/pull/9155) - Allow bypassing avg block time in proxy implementation re-fetch ttl calculation
- [#9148](https://github.com/blockscout/blockscout/pull/9148) - Add `/api/v2/utils/decode-calldata`
- [#9145](https://github.com/blockscout/blockscout/pull/9145) - Proxy for Account abstraction microservice
- [#9132](https://github.com/blockscout/blockscout/pull/9132) - Fetch token image from CoinGecko

@ -98,7 +98,7 @@ defmodule Explorer.Chain.Search do
basic_query
|> union(^address_query)
valid_tx_or_op_hash?(string) ->
valid_full_hash?(string) ->
tx_query = search_tx_query(string)
if UserOperation.user_operations_enabled?() do
@ -172,7 +172,7 @@ defmodule Explorer.Chain.Search do
|> select_repo(options).all()
tx_result =
if valid_tx_or_op_hash?(search_query) do
if valid_full_hash?(search_query) do
search_query
|> search_tx_query()
|> select_repo(options).all()
@ -181,7 +181,7 @@ defmodule Explorer.Chain.Search do
end
op_result =
if valid_tx_or_op_hash?(search_query) && UserOperation.user_operations_enabled?() do
if valid_full_hash?(search_query) && UserOperation.user_operations_enabled?() do
search_query
|> search_user_operation_query()
|> select_repo(options).all()
@ -372,7 +372,7 @@ defmodule Explorer.Chain.Search do
end
end
defp valid_tx_or_op_hash?(string_input) do
defp valid_full_hash?(string_input) do
case Chain.string_to_transaction_hash(string_input) do
{:ok, _tx_hash} -> true
_ -> false

@ -68,10 +68,6 @@ defmodule Explorer.Chain.UserOperation do
end
def user_operations_enabled? do
if Microservice.check_enabled(Explorer.MicroserviceInterfaces.AccountAbstraction) == :ok do
true
else
false
end
Microservice.check_enabled(Explorer.MicroserviceInterfaces.AccountAbstraction) == :ok
end
end

Loading…
Cancel
Save