1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
metamask-extension/ui/app/pages
Mark Stacey f39498703e Use pathname instead of URL for currentPath metrics parameter (#9158)
The `currentPath` parameter passed to our metrics utility had been
passed the full URL rather than just the path, contrary to what the
name would imply. We only used the path portion, so passing the full
URL did lead to complications.

Now just the `pathname` is passed in, rather than the full URL. This
simplifies the metrics logic, and it incidentally fixes two bugs.

The main bug fixed is regarding Firefox metrics. Previously we had
assumed the `currentPath` would start with `chrome-extension://`, which
of course was not true on Firefox. This lead to us incorrectly parsing
the `currentPath`, so path tracking was broken for Firefox events.
This broken parsing is now bypassed entirely, so metrics should now
work the same on Firefox as on Chrome.

The second bug was that we were incorrectly setting the tracking URL
for background events during tests. As a result, we were incorrectly
detecting ourselves as an internal site that had referred the user to
us. But this was not of major concern, since it only affected test
metrics (which get sent to the development Matomo project).

Lastly, this change let us discard the `pathname` parameter used in
the `overrides` parameter of the `metricsEvent` function. Now that
`currentPath` is equivalent to `pathname`, the `pathname` parameter is
redundant.
2020-08-07 16:42:48 -03:00
..
add-token Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
asset Uncomment and fix all auto-fixable stylelint rules (#8989) 2020-07-15 10:13:40 -03:00
confirm-add-suggested-token Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-add-token Uncomment and fix all auto-fixable stylelint rules (#8989) 2020-07-15 10:13:40 -03:00
confirm-approve Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
confirm-decrypt-message Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-deploy-contract
confirm-encryption-public-key Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-send-ether Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-send-token Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-token-transaction-base Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-transaction Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-transaction-base Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
confirm-transaction-switch
connected-accounts Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
connected-sites Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
create-account Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
error Uncomment and fix all auto-fixable stylelint rules (#8989) 2020-07-15 10:13:40 -03:00
first-time-flow Complete onboarding upon importing/verifying seed (#8873) 2020-08-07 16:42:47 -03:00
home Skip render when home page is closing or redirecting (#9012) 2020-07-16 15:23:07 -03:00
keychains Uncomment and fix all auto-fixable stylelint rules (#8989) 2020-07-15 10:13:40 -03:00
lock Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
mobile-sync Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
permissions-connect Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
routes Use pathname instead of URL for currentPath metrics parameter (#9158) 2020-08-07 16:42:48 -03:00
send Fix words (#9038) 2020-07-20 14:32:49 -02:30
settings update email us to contact us (#9104) 2020-08-07 16:42:48 -03:00
unlock-page Fix words (#9038) 2020-07-20 14:32:49 -02:30
index.js
index.scss Uncomment and fix all auto-fixable stylelint rules (#8989) 2020-07-15 10:13:40 -03:00