Commit dd773b9e authored by 杨奕's avatar 杨奕 Committed by GitHub

InputNumber: fix accessing missing $refs in updated hook (#10995)

parent 31b65b8e
...@@ -216,7 +216,8 @@ ...@@ -216,7 +216,8 @@
innerInput.setAttribute('aria-disabled', this.inputNumberDisabled); innerInput.setAttribute('aria-disabled', this.inputNumberDisabled);
}, },
updated() { updated() {
let innerInput = this.$refs.input.$refs.input; if (!this.$refs || !this.$refs.input) return;
const innerInput = this.$refs.input.$refs.input;
innerInput.setAttribute('aria-valuenow', this.currentValue); innerInput.setAttribute('aria-valuenow', this.currentValue);
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment