Skip to content

Commit

Permalink
Merge pull request #4979 from thematters/fix/tracker
Browse files Browse the repository at this point in the history
fix(tracker): fix read timer does not work if user bounces immediately
  • Loading branch information
zeckli authored Dec 12, 2024
2 parents 9d19a63 + 8ef9026 commit b6458cc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/Hook/useReadTimer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export const useReadTimer = ({ articleId, container }: Props) => {
}, 3000)

const storeReadTime = () => {
if (articleId && readTimer?.current)
if (articleId && readTimer)
analytics.trackEvent('read_time', {
articleId,
time: readTimer.current,
Expand Down

0 comments on commit b6458cc

Please sign in to comment.