From 3cd5b4023f54e7af16bcb69fcf7dd3a33ff9dcaf Mon Sep 17 00:00:00 2001 From: neverland Date: Wed, 29 Jul 2020 10:55:54 +0800 Subject: [PATCH] fix(Popup): incorrect lock scroll in some cases (#6892) --- src/mixins/popup/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/mixins/popup/index.js b/src/mixins/popup/index.js index c2c97d40b..a0182e133 100644 --- a/src/mixins/popup/index.js +++ b/src/mixins/popup/index.js @@ -99,9 +99,12 @@ export function PopupMixin(options = {}) { }, beforeDestroy() { - this.removeLock(); removeOverlay(this); + if (this.opened) { + this.removeLock(); + } + if (this.getContainer) { removeNode(this.$el); }