Fixed headers response data

This commit is contained in:
Claudio Sanches 2016-11-22 22:48:31 -02:00
parent a98c4b429f
commit 5d1c074998
1 changed files with 2 additions and 1 deletions

View File

@ -25,7 +25,8 @@ if ( ! defined( 'ABSPATH' ) ) {
<p><strong><?php _e( 'Status', 'woocommerce' ); ?>: </strong><?php echo esc_html( $log['summary'] ); ?></p>
<p><strong><?php _e( 'Headers', 'woocommerce' ); ?>:</strong></p>
<ul>
<?php foreach ( (array) $log['response_headers'] as $key => $value ) : ?>
<?php $response_headers = is_callable( array( $log['response_headers'], 'getAll' ) ) ? $log['response_headers']->getAll() : $log['response_headers']; ?>
<?php foreach ( (array) $response_headers as $key => $value ) : ?>
<li><strong><em><?php echo strtolower( esc_html( $key ) ); ?>: </em></strong><code><?php echo esc_html( $value ); ?></code></li>
<?php endforeach ?>
</ul>