@@ 208-211 (lines=4) @@ | ||
205 | ||
206 | $class = __NAMESPACE__ . '\\' . $type . '_Field'; |
|
207 | ||
208 | if ( ! class_exists( $class ) ) { |
|
209 | Incorrect_Syntax_Exception::raise( 'Unknown field "' . $type . '".' ); |
|
210 | $class = __NAMESPACE__ . '\\Broken_Field'; |
|
211 | } |
|
212 | ||
213 | $field = new $class( $type, $name, $label ); |
|
214 |
@@ 148-151 (lines=4) @@ | ||
145 | $normalized_type = Helper::normalize_type( $type ); |
|
146 | $class = Helper::type_to_class( $normalized_type, __NAMESPACE__, '_Container' ); |
|
147 | ||
148 | if ( ! class_exists( $class ) ) { |
|
149 | Incorrect_Syntax_Exception::raise( 'Unknown container "' . $type . '".' ); |
|
150 | $class = __NAMESPACE__ . '\\Broken_Container'; |
|
151 | } |
|
152 | ||
153 | $repository = App::resolve( 'container_repository' ); |
|
154 | $unique_id = $repository->get_unique_panel_id( $name ); |