Add logging status to status report

This commit is contained in:
Alex P 2021-11-19 17:25:47 +02:00
parent 77d3a5c19c
commit 9ba675d1f5

View file

@ -44,6 +44,8 @@ class StatusReportModule implements ModuleInterface {
add_action(
'woocommerce_system_status_report',
function () use ( $c ) {
$settings = $c->get( 'wcgateway.settings' );
assert( $settings instanceof ContainerInterface );
/* @var State $state The state. */
$state = $c->get( 'onboarding.state' );
@ -94,6 +96,13 @@ class StatusReportModule implements ModuleInterface {
$this->vault_enabled( $bearer )
),
),
array(
'label' => esc_html__( 'Logging enabled', 'woocommerce-paypal-payments' ),
'description' => esc_html__( 'Whether logging of plugin events and errors is enabled.', 'woocommerce-paypal-payments' ),
'value' => $this->bool_to_text(
$settings->has( 'logging_enabled' ) && $settings->get( 'logging_enabled' )
),
),
);
echo wp_kses_post(