core/Helper/Helper.php 1 location
|
@@ 223-226 (lines=4) @@
|
220 |
|
$relation = strtoupper( $array[ $relation_key ] ); |
221 |
|
} |
222 |
|
|
223 |
|
if ( ! in_array( $relation, $allowed_relations ) ) { |
224 |
|
Incorrect_Syntax_Exception::raise( 'Invalid relation type ' . $relation . '. ' . |
225 |
|
'The rule should be one of the following: "' . implode( '", "', $allowed_relations ) . '"' ); |
226 |
|
} |
227 |
|
|
228 |
|
return $relation; |
229 |
|
} |
core/Field/Complex_Field.php 1 location
|
@@ 536-542 (lines=7) @@
|
533 |
|
static::LAYOUT_TABBED_VERTICAL, |
534 |
|
); |
535 |
|
|
536 |
|
if ( ! in_array( $layout, $available_layouts ) ) { |
537 |
|
$error_message = 'Incorrect layout ``' . $layout . '" specified. ' . |
538 |
|
'Available layouts: ' . implode( ', ', $available_layouts ); |
539 |
|
|
540 |
|
Incorrect_Syntax_Exception::raise( $error_message ); |
541 |
|
return $this; |
542 |
|
} |
543 |
|
|
544 |
|
$this->layout = $layout; |
545 |
|
|
core/Field/Field.php 1 location
|
@@ 938-943 (lines=6) @@
|
935 |
|
'value' => '', |
936 |
|
), $rule ); |
937 |
|
|
938 |
|
if ( ! in_array( $rule['compare'], $allowed_operators ) ) { |
939 |
|
Incorrect_Syntax_Exception::raise( 'Invalid conditional logic compare operator: <code>' . $rule['compare'] . '</code><br>Allowed operators are: <code>' . |
940 |
|
implode( ', ', $allowed_operators ) . '</code>' ); |
941 |
|
return array(); |
942 |
|
} |
943 |
|
|
944 |
|
if ( in_array( $rule['compare'], array( 'IN', 'NOT IN' ) ) && ! is_array( $rule['value'] ) ) { |
945 |
|
Incorrect_Syntax_Exception::raise( 'Invalid conditional logic value format. An array is expected, when using the "' . $rule['compare'] . '" operator.' ); |
946 |
|
return array(); |