Completed
Branch develop (a31803)
by Laurent
21:16
created
htdocs/adherents/class/adherent_type.class.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -241,12 +241,12 @@
 block discarded – undo
241 241
 	}
242 242
 
243 243
 	   /**
244
-		* Delete a language for this member type
245
-		*
246
-		* @param string $langtodelete 	Language code to delete
247
-		* @param User   $user         	Object user making delete
248
-		* @return int                   <0 if KO, >0 if OK
249
-		*/
244
+	    * Delete a language for this member type
245
+	    *
246
+	    * @param string $langtodelete 	Language code to delete
247
+	    * @param User   $user         	Object user making delete
248
+	    * @return int                   <0 if KO, >0 if OK
249
+	    */
250 250
 	public function delMultiLangs($langtodelete, $user)
251 251
 	{
252 252
 		$sql = "DELETE FROM ".MAIN_DB_PREFIX."adherent_type_lang";
Please login to merge, or discard this patch.
htdocs/product/stock/productlot_list.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -110,7 +110,9 @@
 block discarded – undo
110 110
 	accessforbidden();
111 111
 }
112 112
 //$result = restrictedArea($user, 'productbatch');
113
-if (!$permissiontoread) accessforbidden();
113
+if (!$permissiontoread) {
114
+	accessforbidden();
115
+}
114 116
 
115 117
 
116 118
 /*
Please login to merge, or discard this patch.
htdocs/eventorganization/conferenceorboothattendee_list.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -152,7 +152,9 @@
 block discarded – undo
152 152
 	accessforbidden();
153 153
 }
154 154
 $result = restrictedArea($user, 'eventorganization');
155
-if (!$permissiontoread) accessforbidden();
155
+if (!$permissiontoread) {
156
+	accessforbidden();
157
+}
156 158
 
157 159
 
158 160
 /*
Please login to merge, or discard this patch.
htdocs/projet/class/project.class.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -126,8 +126,8 @@
 block discarded – undo
126 126
 	public $usage_bill_time; // Is the time spent on project must be invoiced or not
127 127
 
128 128
 	/**
129
-	   * @var integer		Event organization: Use Event Organization
130
-	   */
129
+	 * @var integer		Event organization: Use Event Organization
130
+	 */
131 131
 	public $usage_organize_event;
132 132
 
133 133
 	/**
Please login to merge, or discard this patch.
htdocs/compta/tva/class/tva.class.php 1 patch
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -416,7 +416,7 @@  discard block
 block discarded – undo
416 416
 		return $solde;
417 417
 	}
418 418
 
419
-    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
419
+	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
420 420
 	/**
421 421
 	 * 	Total of the VAT from invoices emitted by the thirdparty.
422 422
 	 *
@@ -425,7 +425,7 @@  discard block
 block discarded – undo
425 425
 	 */
426 426
 	public function tva_sum_collectee($year = 0)
427 427
 	{
428
-        // phpcs:enable
428
+		// phpcs:enable
429 429
 
430 430
 		$sql = "SELECT sum(f.total_tva) as amount";
431 431
 		$sql .= " FROM ".MAIN_DB_PREFIX."facture as f WHERE f.paye = 1";
@@ -450,7 +450,7 @@  discard block
 block discarded – undo
450 450
 		}
451 451
 	}
452 452
 
453
-    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
453
+	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
454 454
 	/**
455 455
 	 * 	VAT payed
456 456
 	 *
@@ -459,7 +459,7 @@  discard block
 block discarded – undo
459 459
 	 */
460 460
 	public function tva_sum_payee($year = 0)
461 461
 	{
462
-        // phpcs:enable
462
+		// phpcs:enable
463 463
 
464 464
 		$sql = "SELECT sum(f.total_tva) as total_tva";
465 465
 		$sql .= " FROM ".MAIN_DB_PREFIX."facture_fourn as f";
@@ -485,7 +485,7 @@  discard block
 block discarded – undo
485 485
 	}
486 486
 
487 487
 
488
-    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
488
+	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
489 489
 	/**
490 490
 	 * 	Total of the VAT payed
491 491
 	 *
@@ -494,7 +494,7 @@  discard block
 block discarded – undo
494 494
 	 */
495 495
 	public function tva_sum_reglee($year = 0)
496 496
 	{
497
-        // phpcs:enable
497
+		// phpcs:enable
498 498
 
499 499
 		$sql = "SELECT sum(f.amount) as amount";
500 500
 		$sql .= " FROM ".MAIN_DB_PREFIX."tva as f";
@@ -665,7 +665,7 @@  discard block
 block discarded – undo
665 665
 		}
666 666
 	}
667 667
 
668
-    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
668
+	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
669 669
 	/**
670 670
 	 *  Update link between payment tva and line generate into llx_bank
671 671
 	 *
@@ -674,7 +674,7 @@  discard block
 block discarded – undo
674 674
 	 */
675 675
 	public function update_fk_bank($id_bank)
676 676
 	{
677
-        // phpcs:enable
677
+		// phpcs:enable
678 678
 		$sql = 'UPDATE '.MAIN_DB_PREFIX.'tva SET fk_bank = '.(int) $id_bank;
679 679
 		$sql .= ' WHERE rowid = '.(int) $this->id;
680 680
 		$result = $this->db->query($sql);
Please login to merge, or discard this patch.
htdocs/societe/checkvat/checkVatPopup.php 1 patch
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,10 @@
 block discarded – undo
21 21
  *		\brief      Popup screen to validate VAT
22 22
  */
23 23
 
24
-if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL', '1');		// Do not roll the Anti CSRF token (used if MAIN_SECURITY_CSRF_WITH_TOKEN is on)
24
+if (! defined('NOTOKENRENEWAL')) {
25
+	define('NOTOKENRENEWAL', '1');
26
+}
27
+// Do not roll the Anti CSRF token (used if MAIN_SECURITY_CSRF_WITH_TOKEN is on)
25 28
 
26 29
 require "../../main.inc.php";
27 30
 require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
Please login to merge, or discard this patch.
htdocs/knowledgemanagement/class/knowledgerecord.class.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -820,7 +820,9 @@
 block discarded – undo
820 820
 		}
821 821
 
822 822
 		$statusType = 'status'.$status;
823
-		if ($status == self::STATUS_VALIDATED) $statusType = 'status4';
823
+		if ($status == self::STATUS_VALIDATED) {
824
+			$statusType = 'status4';
825
+		}
824 826
 		if ($status == self::STATUS_CANCELED) {
825 827
 			$statusType = 'status6';
826 828
 		}
Please login to merge, or discard this patch.
htdocs/website/index.php 1 patch
Braces   +18 added lines, -6 removed lines patch added patch discarded remove patch
@@ -26,7 +26,9 @@  discard block
 block discarded – undo
26 26
 define('NOSTYLECHECK', 1);
27 27
 define('USEDOLIBARREDITOR', 1);
28 28
 define('FORCE_CKEDITOR', 1); // We need CKEditor, even if module is off.
29
-if (!defined('DISABLE_JS_GRAHP')) define('DISABLE_JS_GRAPH', 1);
29
+if (!defined('DISABLE_JS_GRAHP')) {
30
+	define('DISABLE_JS_GRAPH', 1);
31
+}
30 32
 
31 33
 //header('X-XSS-Protection:0');	// Disable XSS filtering protection of some browsers (note: use of Content-Security-Policy is more efficient). Disabled as deprecated.
32 34
 
@@ -592,7 +594,9 @@  discard block
 block discarded – undo
592 594
 		$arrayotherlang = explode(',', GETPOST('WEBSITE_OTHERLANG', 'alphanohtml'));
593 595
 		foreach ($arrayotherlang as $key => $val) {
594 596
 			// It possible we have empty val here if postparam WEBSITE_OTHERLANG is empty or set like this : 'en,,sv' or 'en,sv,'
595
-			if (empty(trim($val))) continue;
597
+			if (empty(trim($val))) {
598
+				continue;
599
+			}
596 600
 			$arrayotherlang[$key] = substr(trim($val), 0, 2); // Kept short language code only
597 601
 		}
598 602
 
@@ -1336,7 +1340,9 @@  discard block
 block discarded – undo
1336 1340
 				$arrayotherlang = explode(',', GETPOST('WEBSITE_OTHERLANG', 'alphanohtml'));
1337 1341
 				foreach ($arrayotherlang as $key => $val) {
1338 1342
 					// It possible we have empty val here if postparam WEBSITE_OTHERLANG is empty or set like this : 'en,,sv' or 'en,sv,'
1339
-					if (empty(trim($val))) continue;
1343
+					if (empty(trim($val))) {
1344
+						continue;
1345
+					}
1340 1346
 					$arrayotherlang[$key] = substr(trim($val), 0, 2); // Kept short language code only
1341 1347
 				}
1342 1348
 
@@ -1793,7 +1799,9 @@  discard block
 block discarded – undo
1793 1799
 					// Under certain conditions $sublang can be an empty string
1794 1800
 					// ($object->otherlang with empty string or with string like this 'en,,sv')
1795 1801
 					// if is the case we try to re-delete the main alias file. Avoid it.
1796
-					if (empty(trim($sublang))) continue;
1802
+					if (empty(trim($sublang))) {
1803
+						continue;
1804
+					}
1797 1805
 					$fileoldaliassub = $dirname.'/'.$sublang.'/'.$filename;
1798 1806
 					dol_delete_file($fileoldaliassub);
1799 1807
 				}
@@ -1816,7 +1824,9 @@  discard block
 block discarded – undo
1816 1824
 							// Under certain conditions $ sublang can be an empty string
1817 1825
 							// ($object->otherlang with empty string or with string like this 'en,,sv')
1818 1826
 							// if is the case we try to re-delete the main alias file. Avoid it.
1819
-							if (empty(trim($sublang))) continue;
1827
+							if (empty(trim($sublang))) {
1828
+								continue;
1829
+							}
1820 1830
 							$fileoldaliassub = $dirname.'/'.$sublang.'/'.$filename;
1821 1831
 							dol_delete_file($fileoldaliassub);
1822 1832
 						}
@@ -2903,7 +2913,9 @@  discard block
 block discarded – undo
2903 2913
 							$onlylang[$website->lang] = $website->lang.' ('.$langs->trans("Default").')';
2904 2914
 						}
2905 2915
 						foreach (explode(',', $website->otherlang) as $langkey) {
2906
-							if (empty(trim($langkey))) continue;
2916
+							if (empty(trim($langkey))) {
2917
+								continue;
2918
+							}
2907 2919
 							$onlylang[$langkey] = $langkey;
2908 2920
 						}
2909 2921
 						$textifempty = $langs->trans("Default");
Please login to merge, or discard this patch.
htdocs/contrat/card.php 1 patch
Braces   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1984,9 +1984,12 @@
 block discarded – undo
1984 1984
 
1985 1985
 				$parameters = array();
1986 1986
 				$reshook = $hookmanager->executeHooks('formAddObjectLine', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
1987
-				if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
1988
-				if (empty($reshook))
1989
-					$object->formAddObjectLine(1, $mysoc, $soc);
1987
+				if ($reshook < 0) {
1988
+					setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
1989
+				}
1990
+				if (empty($reshook)) {
1991
+									$object->formAddObjectLine(1, $mysoc, $soc);
1992
+				}
1990 1993
 			}
1991 1994
 
1992 1995
 			print '</table>';
Please login to merge, or discard this patch.