if matomo is undefined, don't try to use it
This commit is contained in:
parent
b0d34d4e48
commit
dc50b40b69
@ -141,9 +141,11 @@ export class EnterpriseService {
|
|||||||
|
|
||||||
page() {
|
page() {
|
||||||
const matomo = this.getMatomo();
|
const matomo = this.getMatomo();
|
||||||
|
if (matomo) {
|
||||||
matomo.setCustomUrl(this.getCustomUrl());
|
matomo.setCustomUrl(this.getCustomUrl());
|
||||||
matomo.trackPageView();
|
matomo.trackPageView();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private getCustomUrl(): string {
|
private getCustomUrl(): string {
|
||||||
let url = window.location.origin + '/';
|
let url = window.location.origin + '/';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user