Simplify logic in is_detached()

This commit is contained in:
Matt Sherman 2023-09-15 12:54:16 -04:00
parent 68607e02e8
commit e03acdf662
1 changed files with 1 additions and 1 deletions

View File

@ -189,7 +189,7 @@ class AbstractBlock implements BlockInterface {
$is_in_parent = $this->parent->get_block( $this->id ) === $this;
$is_in_root_template = $this->get_root_template()->get_block( $this->id ) === $this;
return ! $is_in_parent || ! $is_in_root_template;
return ! ( $is_in_parent && $is_in_root_template );
}
/**
* Get the block configuration as a formatted template.