From b6308f6dfa8adfbe50cae5352298850d1e7f9665 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 26 May 2020 01:16:18 +0200 Subject: [PATCH] Fix phpcs --- htdocs/product/list.php | 7 ++----- test/phpunit/LangTest.php | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/htdocs/product/list.php b/htdocs/product/list.php index d5eaa81d06f..ff5f6ee5047 100644 --- a/htdocs/product/list.php +++ b/htdocs/product/list.php @@ -217,12 +217,9 @@ if ($conf->global->PRODUIT_MULTIPRICES){ for ($i = 1; $i <= $conf->global->PRODUIT_MULTIPRICES_LIMIT; $i++) { $keyforlabel = 'PRODUIT_MULTIPRICES_LABEL'.$i; - if (!empty($conf->global->$keyforlabel)) - { + if (!empty($conf->global->$keyforlabel)) { $labelp = $i.' - '.$langs->trans($conf->global->$keyforlabel); - } - else - { + } else { $labelp = $langs->trans("SellingPrice")." ".$i; } $arrayfields['p.sellprice'.$i] = array('label'=>$labelp, 'checked'=>1, 'enabled'=>$conf->global->PRODUIT_MULTIPRICES, 'position'=>40); diff --git a/test/phpunit/LangTest.php b/test/phpunit/LangTest.php index 73e826cf75a..c064a03e2f8 100644 --- a/test/phpunit/LangTest.php +++ b/test/phpunit/LangTest.php @@ -183,7 +183,7 @@ class LangTest extends PHPUnit\Framework\TestCase unset($tmplangs); $filesarray2 = scandir(DOL_DOCUMENT_ROOT.'/langs/'.$code); - foreach($filesarray2 as $key => $file) { + foreach ($filesarray2 as $key => $file) { if (! preg_match('/\.lang$/', $file)) { continue; }