mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 09:45:04 +01:00
Add guard around location redirect.
This commit is contained in:
parent
4bad94f436
commit
99c8752aa5
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "umami",
|
||||
"version": "1.39.0-beta.1",
|
||||
"version": "1.39.0-beta.2",
|
||||
"description": "A simple, fast, privacy-focused alternative to Google Analytics.",
|
||||
"author": "Mike Cao <mike@mikecao.com>",
|
||||
"license": "MIT",
|
||||
|
@ -143,7 +143,10 @@
|
||||
) {
|
||||
e.preventDefault();
|
||||
trackEvent(name).then(() => {
|
||||
location.href = get('href');
|
||||
const href = get('href');
|
||||
if (href) {
|
||||
location.href = href;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
trackEvent(name);
|
||||
|
Loading…
Reference in New Issue
Block a user