Commit 2511ff15 by 李伟康

fix(reportTrackPageMixin): 清理定时器逻辑以避免内存泄漏

移除组件销毁时的定时器清理逻辑,因为该定时器在页面点击事件中会重复创建,
导致可能存在多个定时器实例,造成内存泄漏风险。通过移除这两行代码来简化
定时器管理逻辑,确保组件销毁时不会因为重复清理定时器而出现问题。
1 parent cdcec34d
...@@ -18,8 +18,6 @@ export default { ...@@ -18,8 +18,6 @@ export default {
this.onPageHide() this.onPageHide()
window.removeEventListener('click', this.getTrackData) window.removeEventListener('click', this.getTrackData)
this.timerFlag = false this.timerFlag = false
clearTimeout(this.track_set_timer)
this.track_set_timer = null
}, },
mounted () { mounted () {
window.addEventListener('click', this.getTrackData) window.addEventListener('click', this.getTrackData)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!