Automattic\WooCommerce\Internal\Logging

RemoteLogger::is_dev_or_local_environmentprotectedWC 1.0

Check if the current environment is development or local.

Creates a helper method so we can easily mock this in tests.

Method of the class: RemoteLogger{}

No Hooks.

Returns

true|false.

Usage

// protected - for code of main (parent) or child class
$result = $this->is_dev_or_local_environment();

RemoteLogger::is_dev_or_local_environment() code WC 9.9.4

protected function is_dev_or_local_environment() {
	return in_array( SafeGlobalFunctionProxy::wp_get_environment_type() ?? 'production', array( 'development', 'local' ), true );
}