ActionScheduler::is_initialized()
Check whether the AS data store has been initialized.
Method of the class: ActionScheduler{}
No Hooks.
Return
true|false
.
Usage
$result = ActionScheduler::is_initialized( $function_name );
- $function_name(string)
- The name of the function being called. Optional.
Default: null
ActionScheduler::is_initialized() ActionScheduler::is initialized code WC 8.7.0
public static function is_initialized( $function_name = null ) { if ( ! self::$data_store_initialized && ! empty( $function_name ) ) { $message = sprintf( /* translators: %s function name. */ __( '%s() was called before the Action Scheduler data store was initialized', 'woocommerce' ), esc_attr( $function_name ) ); _doing_it_wrong( $function_name, $message, '3.1.6' ); } return self::$data_store_initialized; }