diff --git a/includes/class.field_type.php b/includes/class.field_type.php index f6fcd39..1eb7ba1 100644 --- a/includes/class.field_type.php +++ b/includes/class.field_type.php @@ -432,7 +432,7 @@ public function process_placeholders( $str, $layout = 'form', $data = null ) { // Iterate through instances of current placeholder foreach ( $instances as $instance ) { // Process value based on placeholder name. - $target_property = $this->util->apply_filters_ref_array( "process_placeholder_${tag}", [ '', $this, &$instance, $layout, $data ], false ); + $target_property = $this->util->apply_filters_ref_array( "process_placeholder_{$tag}", [ '', $this, &$instance, $layout, $data ], false ); // Process value using default processors (if necessary). if ( '' === $target_property ) { $target_property = $this->util->apply_filters_ref_array( 'process_placeholder', [ $target_property, $this, &$instance, $layout, $data ], false ); diff --git a/includes/class.options.php b/includes/class.options.php index f481ab3..f862f92 100644 --- a/includes/class.options.php +++ b/includes/class.options.php @@ -498,7 +498,7 @@ function get_key() { function &add( $id, $properties = array(), $update = false ) { // Create item $args = func_get_args(); - $ret = call_user_func_array( array( 'parent', 'add' ), $args ); + $ret = call_user_func_array( array( parent::class, 'add' ), $args ); return $ret; } diff --git a/includes/class.utilities.php b/includes/class.utilities.php index fe5d6ef..4945254 100644 --- a/includes/class.utilities.php +++ b/includes/class.utilities.php @@ -542,7 +542,9 @@ public function validate_client_object( $obj, $cmd = null ) { // Build condition $sep = '.'; + $obj = $obj ? $obj : ''; $obj = trim( $obj, $sep ); + // Strip base object if ( 0 === strpos( $obj, $base . $sep ) ) { $obj = substr( $obj, strlen( $base . $sep ) );