1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
metamask-extension/ui/app
bguiz 96929d99c0 fix: handle trailing / in block explorer URLs
What

- modify `ui/app/helpers/utils/transactions.util.js` and
  `ui/lib/account-link.js` to strip trailing slashes
  if they are present.
- added relevant tests not just for the new scenario,
  but also the general scenarios for these functions,
  as there previously was no test coverage for these
  two functions.

Why

- Current behaviour, when user enters a block explorer URL
  when configuring a custom RPC, and that block explorer URL
  contains a trailing `/`.
  - e.g. `https://block.explorer/`
  - this results in a double-slash (`//`) in the transaction
    and account URLs generated by MetaMask.
  - e.g. `https://block.explorer/tx/0xabcd...`,
    `https://block.explorer/account/0xabcd...`
  - This needs to be handled using a router redirect
    on the server of the block explorer,
    and this changes would avoid that requirement.
2020-05-14 17:15:17 +08:00
..
components broaden usage options for list-item (#8587) 2020-05-13 16:19:14 -05:00
contexts Use createContext for metametrics context (preserve legacy context) (#8540) 2020-05-08 11:41:43 -05:00
css set home container height to auto (#8577) 2020-05-13 11:12:34 -05:00
ducks Add default values for preferences (#8584) 2020-05-13 11:53:00 -03:00
helpers fix: handle trailing / in block explorer URLs 2020-05-14 17:15:17 +08:00
hooks factor out containers for currency components (#8543) 2020-05-12 14:07:35 -05:00
pages set home container height to auto (#8577) 2020-05-13 11:12:34 -05:00
selectors Always return a Boolean from getShowFiatSelector (#8585) 2020-05-13 11:53:27 -03:00
store Delete retryTransaction action and background (#8576) 2020-05-12 16:19:33 -07:00