← All changes
|
modules/mcp/abilities/utils/llm-guidance-builder.php
+2
-1
4.3.0-beta1
→
4.3.2
View file →
| @@ -59,9 +59,10 @@ | ||
| 59 | 59 | } |
| 60 | 60 | |
| 61 | 61 | private static function build_nesting( array $config, string $widget_type, array $parents_index ): array { |
| 62 | 62 | $allowed_child_types = $config['allowed_child_types'] ?? []; |
| 63 | - $allowed_parents = $parents_index[ $widget_type ] ?? []; | |
| 63 | + $emit_allowed_parents = empty( $config['show_in_panel'] ); | |
| 64 | + $allowed_parents = $emit_allowed_parents ? ( $parents_index[ $widget_type ] ?? [] ) : []; | |
| 64 | 65 | |
| 65 | 66 | return array_filter( |
| 66 | 67 | [ |
| 67 | 68 | 'allowed_child_types' => empty( $allowed_child_types ) ? null : $allowed_child_types, |