mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
[IMP] component: validate mounting target at patch time
This commit is contained in:
committed by
Aaron Bohy
parent
bd98d4d0d0
commit
50aac42bdc
@@ -1,4 +1,5 @@
|
||||
import { BDom, mount } from "../blockdom";
|
||||
import { validateTarget } from "../utils";
|
||||
import type { ComponentNode } from "./component_node";
|
||||
import { fibersInError, handleError } from "./error_handling";
|
||||
import { STATUS } from "./status";
|
||||
@@ -158,6 +159,7 @@ export class MountFiber extends RootFiber {
|
||||
complete() {
|
||||
let current: Fiber | undefined = this;
|
||||
try {
|
||||
validateTarget(this.target);
|
||||
const node = this.node;
|
||||
if (node.bdom) {
|
||||
// this is a complicated situation: if we mount a fiber with an existing
|
||||
|
||||
Reference in New Issue
Block a user