vindi/vindi-woocommerce

View on GitHub
src/views/product-status.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php
/**
* Admin View: Notice - Invalid token message.
*/
 
Expected 0 spaces before closing bracket; 1 found
Space after opening parenthesis of function call prohibited
Expected 0 spaces after opening bracket; 1 found
if ( ! defined( 'ABSPATH' ) ) {
Spaces must be used to indent lines; tabs are not allowed
exit;
}
 
$type = get_transient('vindi_product_message');
?>
 
Expected 1 space after closing parenthesis; found 0
<?php if ($type == 'created'): ?>
<div class="vindi-alert notice vindi-success">
Spaces must be used to indent lines; tabs are not allowed
Line exceeds 120 characters; contains 138 characters
Space after opening parenthesis of function call prohibited
Expected 0 spaces before closing bracket; 1 found
<p><strong><?php _e('Vindi', VINDI);?></strong>: <?php printf( __( 'O produto foi criado na Vindi com sucesso!', VINDI ) ); ?></p>
Spaces must be used to indent lines; tabs are not allowed
</div>
Expected 1 space after closing parenthesis; found 0
<?php elseif ($type == 'updated'): ?>
<div class="vindi-alert notice vindi-success">
Line exceeds 120 characters; contains 142 characters
Spaces must be used to indent lines; tabs are not allowed
Space after opening parenthesis of function call prohibited
Expected 0 spaces before closing bracket; 1 found
<p><strong><?php _e('Vindi', VINDI);?></strong>: <?php printf( __( 'O produto foi atualizado na Vindi com sucesso!', VINDI ) ); ?></p>
Spaces must be used to indent lines; tabs are not allowed
</div>
Expected 1 space after ELSE keyword; 0 found
<?php else: ?>
<div class="vindi-alert notice vindi-error">
Spaces must be used to indent lines; tabs are not allowed
Line exceeds 120 characters; contains 150 characters
Expected 0 spaces before closing bracket; 1 found
Space after opening parenthesis of function call prohibited
<p><strong><?php _e('Vindi', VINDI);?></strong>: <?php printf( __( 'Não foi possível criar/atualizar o produto na Vindi!', VINDI ) ); ?></p>
Spaces must be used to indent lines; tabs are not allowed
</div>
<?php
Spaces must be used to indent lines; tabs are not allowed
Closing brace indented incorrectly; expected 0 spaces, found 4
endif;
 
Spaces must be used to indent lines; tabs are not allowed
delete_transient('vindi_product_message');
?>