diff --git a/src/components/action-buttons.vue b/src/components/action-buttons.vue index ca9f190489..549b1387e9 100644 --- a/src/components/action-buttons.vue +++ b/src/components/action-buttons.vue @@ -61,12 +61,11 @@ const localOnSubmit = (event) => { } const goBack = () => { - window._paq?.push([ - "trackEvent", + window.Piwik?.getTracker()?.trackEvent( "Parcours", "Bouton précédent", - route.fullPath, - ]) + route.fullPath + ) const answerIndex = getAnswerIndexByPath( store.simulation.answers.current, route.fullPath diff --git a/src/plugins/state-service.ts b/src/plugins/state-service.ts index 8722664668..926337d369 100644 --- a/src/plugins/state-service.ts +++ b/src/plugins/state-service.ts @@ -24,7 +24,7 @@ const StateService = { action: "Navigation cancelled", label: failure.toString(), }, - this.$matomo + window.Piwik?.getTracker() ) } else { throw new Error(failure)