Automattic\WooCommerce\EmailEditor\Validator
Schema::non_nullable
Sets the schema as non-nullable.
Method of the class: Schema{}
No Hooks.
Returns
static.
Usage
$Schema = new Schema(); $Schema->non_nullable();
Schema::non_nullable() Schema::non nullable code WC 10.6.2
public function non_nullable() {
$type = $this->schema['type'] ?? null;
return null === $type
? $this->unset_schema_property( 'type' )
: $this->update_schema_property( 'type', is_array( $type ) ? $type[0] : $type );
}