diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index a16a12698d..5c9a3c747b 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -1285,12 +1285,14 @@ export default { handleScroll() { let stepInfo = this.$refs.stepInfo; let debugHeader = this.$refs.debugHeader; - let originWidth = debugHeader.clientWidth; - if (stepInfo.getBoundingClientRect().top <= 178) { - this.isTop = true; - debugHeader.style.width = originWidth + 'px'; - } else { - this.isTop = false; + if (debugHeader) { + let originWidth = debugHeader.clientWidth; + if (stepInfo.getBoundingClientRect().top <= 178) { + this.isTop = true; + debugHeader.style.width = originWidth + 'px'; + } else { + this.isTop = false; + } } } }