Automattic\WooCommerce\Admin\Features

Features::enable()public staticWC 1.0

Enable a toggleable optional feature.

{} It's a method of the class: Features{}

No Hooks.

Return

true|false.

Usage

$result = Features::enable( $feature );
$feature(string) (required)
Feature name.

Code of Features::enable() WC 6.6.1

public static function enable( $feature ) {
	$features = self::get_optional_feature_options();

	if ( isset( $features[ $feature ] ) ) {
		update_option( $features[ $feature ], 'yes' );
		return true;
	}

	return false;
}