Merge pull request #5801 from blockscout/mofhusseini-fix/transactions_do_not_add_subpath

Mofhusseini fix/transactions do not add subpath
pull/5806/head
Victor Baranov 2 years ago committed by GitHub
commit 516f1fc297
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      CHANGELOG.md
  2. 3
      apps/block_scout_web/lib/block_scout_web/controllers/tokens/instance/holder_controller.ex
  3. 4
      apps/block_scout_web/lib/block_scout_web/controllers/transaction_controller.ex

@ -3,6 +3,7 @@
### Features
### Fixes
- [#5786](https://github.com/blockscout/blockscout/pull/5786) - Replace `current_path` with `Controller.current_full_path` in two controllers
### Chore

@ -1,6 +1,7 @@
defmodule BlockScoutWeb.Tokens.Instance.HolderController do
use BlockScoutWeb, :controller
alias BlockScoutWeb.Controller
alias BlockScoutWeb.Tokens.HolderView
alias Explorer.{Chain, Market}
alias Explorer.Chain.Address
@ -61,7 +62,7 @@ defmodule BlockScoutWeb.Tokens.Instance.HolderController do
conn,
"index.html",
token_instance: token_transfer,
current_path: current_path(conn),
current_path: Controller.current_full_path(conn),
token: Market.add_price(token),
total_token_transfers: Chain.count_token_transfers_from_token_hash_and_token_id(hash, token_id)
)

@ -158,7 +158,7 @@ defmodule BlockScoutWeb.TransactionController do
"show_token_transfers.html",
exchange_rate: Market.get_exchange_rate(Explorer.coin()) || Token.null(),
block_height: Chain.block_height(),
current_path: current_path(conn),
current_path: Controller.current_full_path(conn),
show_token_transfers: true,
transaction: transaction
)
@ -187,7 +187,7 @@ defmodule BlockScoutWeb.TransactionController do
conn,
"show_internal_transactions.html",
exchange_rate: Market.get_exchange_rate(Explorer.coin()) || Token.null(),
current_path: current_path(conn),
current_path: Controller.current_full_path(conn),
block_height: Chain.block_height(),
show_token_transfers: Chain.transaction_has_token_transfers?(transaction_hash),
transaction: transaction

Loading…
Cancel
Save