make get node parent mut optionally return a parent
This commit is contained in:
1 parent
21edea62be
commit
e08a2186a6
2 files changed
+20
-3
No files matched your search
@@ -97,7 +97,7 @@ impl<S: State> RealDom<S> {
|
||||
}
|
||||
|
||||
fn resolve_height(&mut self, node_id: RealNodeId) {
|
||||
if let Some((node, parent)) = self.tree.node_parent_mut(node_id) {
|
||||
if let Some((node, Some(parent))) = self.tree.node_parent_mut(node_id) {
|
||||
let height = parent.node_data.height;
|
||||
node.node_data.height = height + 1;
|
||||
unsafe {
|
||||
|
||||
Reference in new issue
Block a user