@@ -1636,13 +1636,13 @@ export function Tracker(functionName, namespace, version, mutSnowplowState, argm
1636
1636
//Clear page ping heartbeat on new page view
1637
1637
clearInterval ( config . activityInterval ) ;
1638
1638
1639
- activityInterval ( config , finalizeContexts ( context , contextCallback ) ) ;
1639
+ activityInterval ( config , context , contextCallback ) ;
1640
1640
}
1641
1641
}
1642
1642
}
1643
1643
}
1644
1644
1645
- function activityInterval ( config , context ) {
1645
+ function activityInterval ( config , context , contextCallback ) {
1646
1646
const executePagePing = ( cb , c ) => {
1647
1647
refreshUrl ( ) ;
1648
1648
cb ( { context : c , pageViewId : getPageViewId ( ) , minXOffset, minYOffset, maxXOffset, maxYOffset } ) ;
@@ -1655,7 +1655,7 @@ export function Tracker(functionName, namespace, version, mutSnowplowState, argm
1655
1655
// There was activity during the heart beat period;
1656
1656
// on average, this is going to overstate the visitDuration by configHeartBeatTimer/2
1657
1657
if ( lastActivityTime + config . configMinimumVisitLength > now . getTime ( ) ) {
1658
- executePagePing ( config . callback , context ) ;
1658
+ executePagePing ( config . callback , finalizeContexts ( context , contextCallback ) ) ;
1659
1659
}
1660
1660
1661
1661
config . activityInterval = setInterval ( heartbeat , config . configHeartBeatTimer ) ;
@@ -1667,7 +1667,7 @@ export function Tracker(functionName, namespace, version, mutSnowplowState, argm
1667
1667
// There was activity during the heart beat period;
1668
1668
// on average, this is going to overstate the visitDuration by configHeartBeatTimer/2
1669
1669
if ( lastActivityTime + config . configHeartBeatTimer > now . getTime ( ) ) {
1670
- executePagePing ( config . callback , context ) ;
1670
+ executePagePing ( config . callback , finalizeContexts ( context , contextCallback ) ) ;
1671
1671
}
1672
1672
} ;
1673
1673
0 commit comments