mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-19 17:38:19 +08:00
core: add null check
This commit is contained in:
1 parent
105608558f
commit
d5e67de7ad
4 files changed
+4
-9
No files matched your search
@@ -111,15 +111,11 @@ export default class DOMAttachedObject {
|
||||
}
|
||||
|
||||
constructor($dom, monitorDetach = false) {
|
||||
if ($dom == null) {
|
||||
return null;
|
||||
}
|
||||
if ($dom == null) return null;
|
||||
this.$dom = $dom;
|
||||
this.id = ++DOMAttachedObject.uniqueIdCounter;
|
||||
this.eventNS = `vj4obj_${this.id}`;
|
||||
this.detached = false;
|
||||
if (monitorDetach) {
|
||||
monitorResource(this);
|
||||
}
|
||||
if (monitorDetach) monitorResource(this);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user