Automattic\WooCommerce\Admin\Features
Features::enable()
Enable a toggleable optional feature.
Method of the class: Features{}
No Hooks.
Return
true|false
.
Usage
$result = Features::enable( $feature );
- $feature(string) (required)
- Feature name.
Features::enable() Features::enable code WC 9.7.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; }