Passed
Push — main ( 324b47...7af4bb )
by Rafael
43:55
created
htdocs/core/actions_sendmails.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -398,7 +398,7 @@
 block discarded – undo
398 398
                         $object->actionmsg = $message; // Long text
399 399
                         $object->actionmsg2 = $actionmsg2; // Short text ($langs->transnoentities('MailSentBy')...);
400 400
                         if (getDolGlobalString('MAIN_MAIL_REPLACE_EVENT_TITLE_BY_EMAIL_SUBJECT')) {
401
-                            $object->actionmsg2     = $subject; // Short text
401
+                            $object->actionmsg2 = $subject; // Short text
402 402
                         }
403 403
 
404 404
                         $object->trackid = $trackid;
Please login to merge, or discard this patch.
htdocs/core/boxes/box_members_subscriptions_by_year.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@
 block discarded – undo
112 112
                 }
113 113
 
114 114
 
115
-                $line = 0;  // @phan-suppress-current-line PhanPluginRedundantAssignment
115
+                $line = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment
116 116
                 $this->info_box_contents[$line][] = array(
117 117
                     'td' => 'class=""',
118 118
                     'text' => $langs->trans("Year"),
Please login to merge, or discard this patch.
htdocs/core/boxes/box_birthdays_members.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@
 block discarded – undo
85 85
             $sql .= " WHERE u.entity IN (" . getEntity('adherent') . ")";
86 86
             $sql .= " AND u.statut = " . Adherent::STATUS_VALIDATED;
87 87
             $sql .= dolSqlDateFilter('u.birth', 0, $tmparray['mon'], 0);
88
-            $sql .= " ORDER BY daya ASC";   // We want to have date of the month sorted by the day without taking into consideration the year
88
+            $sql .= " ORDER BY daya ASC"; // We want to have date of the month sorted by the day without taking into consideration the year
89 89
             $sql .= $this->db->plimit($max, 0);
90 90
 
91 91
             dol_syslog(get_class($this) . "::loadBox", LOG_DEBUG);
Please login to merge, or discard this patch.
htdocs/core/boxes/box_birthdays.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@
 block discarded – undo
94 94
             $sql .= " AND u.statut = " . User::STATUS_ENABLED;
95 95
             $sql .= dolSqlDateFilter('u.dateemployment', 0, $tmparray['mon'], 0);
96 96
             $sql .= " AND u.dateemployment < '" . $this->db->idate(dol_get_first_day($tmparray['year'])) . "'";
97
-            $sql .= " ORDER BY daya ASC";   // We want to have date of the month sorted by the day without taking into consideration the year
97
+            $sql .= " ORDER BY daya ASC"; // We want to have date of the month sorted by the day without taking into consideration the year
98 98
             $sql .= $this->db->plimit($max, 0);
99 99
 
100 100
             dol_syslog(get_class($this) . "::loadBox", LOG_DEBUG);
Please login to merge, or discard this patch.
htdocs/core/boxes/box_graph_product_distribution.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -141,7 +141,7 @@
 block discarded – undo
141 141
         $userid = 0; // No filter on user creation
142 142
 
143 143
         $WIDTH = ($nbofgraph >= 2 || !empty($conf->dol_optimize_smallscreen)) ? '300' : '320';
144
-        $HEIGHT = '150';    // Height require to have 5+1 entries into legend visible.
144
+        $HEIGHT = '150'; // Height require to have 5+1 entries into legend visible.
145 145
 
146 146
         if (isModEnabled("propal") && $user->hasRight('propal', 'lire')) {
147 147
             // Build graphic number of object. $data = array(array('Lib',val1,val2,val3),...)
Please login to merge, or discard this patch.
htdocs/core/customreports.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
 }
192 192
 
193 193
 // Fetch optionals attributes and labels
194
-$extrafields->fetch_name_optionals_label('all');    // We load all extrafields definitions for all objects
194
+$extrafields->fetch_name_optionals_label('all'); // We load all extrafields definitions for all objects
195 195
 //$extrafields->fetch_name_optionals_label($object->table_element_line);
196 196
 
197 197
 $search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_');
@@ -216,14 +216,14 @@  discard block
 block discarded – undo
216 216
     $crits = explode(' ', trim($value)); // the string after the name of the field. Explode on each AND
217 217
     $res = '';
218 218
 
219
-    $i1 = 0;    // count the nb of and criteria added (all fields / criteria)
219
+    $i1 = 0; // count the nb of and criteria added (all fields / criteria)
220 220
     foreach ($crits as $crit) {     // Loop on each AND criteria
221 221
         $crit = trim($crit);
222 222
 
223
-        $i2 = 0;    // count the nb of valid criteria added for this first criteria
223
+        $i2 = 0; // count the nb of valid criteria added for this first criteria
224 224
         $newres = '';
225 225
         $tmpcrits = explode('|', $crit);
226
-        $i3 = 0;    // count the nb of valid criteria added for this current field
226
+        $i3 = 0; // count the nb of valid criteria added for this current field
227 227
         foreach ($tmpcrits as $tmpcrit) {
228 228
             if ($tmpcrit !== '0' && empty($tmpcrit)) {
229 229
                 continue;
@@ -241,8 +241,8 @@  discard block
 block discarded – undo
241 241
                 }
242 242
             }
243 243
 
244
-            $field = preg_replace('/(:[!<>=\s]+:|:in:|:notin:|:like:|:notlike:).*$/', '', $tmpcrit);        // the name of the field
245
-            $tmpcrit = preg_replace('/^.*(:[!<>=\s]+:|:in:|:notin:|:like:|:notlike:)/', '\1', $tmpcrit);    // the condition after the name of the field
244
+            $field = preg_replace('/(:[!<>=\s]+:|:in:|:notin:|:like:|:notlike:).*$/', '', $tmpcrit); // the name of the field
245
+            $tmpcrit = preg_replace('/^.*(:[!<>=\s]+:|:in:|:notin:|:like:|:notlike:)/', '\1', $tmpcrit); // the condition after the name of the field
246 246
             //var_dump($field); var_dump($tmpcrit); var_dump($i3);
247 247
 
248 248
             $newres .= (($i2 > 0 || $i3 > 0) ? ' OR ' : '');
@@ -612,7 +612,7 @@  discard block
 block discarded – undo
612 612
     foreach ($arrayofmesures as $key => $val) {
613 613
         $simplearrayofmesures[$key] = $arrayofmesures[$key]['label'];
614 614
     }
615
-    print $form->multiselectarray('search_measures', $simplearrayofmesures, $search_measures, 0, 0, 'minwidth300', 1, 0, '', '', $langs->trans("Measures"));    // Fill the array $arrayofmeasures with possible fields
615
+    print $form->multiselectarray('search_measures', $simplearrayofmesures, $search_measures, 0, 0, 'minwidth300', 1, 0, '', '', $langs->trans("Measures")); // Fill the array $arrayofmeasures with possible fields
616 616
     print '</div>';
617 617
 
618 618
     // XAxis
@@ -620,14 +620,14 @@  discard block
 block discarded – undo
620 620
     print '<div class="divadvancedsearchfield">';
621 621
     print '<div class="inline-block"><span class="fas fa-ruler-combined paddingright pictofixedwidth" title="' . dol_escape_htmltag($langs->trans("XAxis")) . '"></span><span class="fas fa-caret-down caretdownaxis" title="' . dol_escape_htmltag($langs->trans("XAxis")) . '"></span></div>';
622 622
     //var_dump($arrayofxaxis);
623
-    print $formother->selectXAxisField($object, $search_xaxis, $arrayofxaxis, $langs->trans("XAxis"), 'minwidth300 maxwidth400');   // Fill the array $arrayofxaxis with possible fields
623
+    print $formother->selectXAxisField($object, $search_xaxis, $arrayofxaxis, $langs->trans("XAxis"), 'minwidth300 maxwidth400'); // Fill the array $arrayofxaxis with possible fields
624 624
     print '</div>';
625 625
 
626 626
     // Group by
627 627
     $count = 0;
628 628
     print '<div class="divadvancedsearchfield">';
629 629
     print '<div class="inline-block opacitymedium"><span class="fas fa-ruler-horizontal paddingright pictofixedwidth" title="' . dol_escape_htmltag($langs->trans("GroupBy")) . '"></span></div>';
630
-    print $formother->selectGroupByField($object, $search_groupby, $arrayofgroupby, 'minwidth250 maxwidth300', $langs->trans("GroupBy"));   // Fill the array $arrayofgroupby with possible fields
630
+    print $formother->selectGroupByField($object, $search_groupby, $arrayofgroupby, 'minwidth250 maxwidth300', $langs->trans("GroupBy")); // Fill the array $arrayofgroupby with possible fields
631 631
     print '</div>';
632 632
 
633 633
 
@@ -784,7 +784,7 @@  discard block
 block discarded – undo
784 784
             //var_dump($arrayofgroupby);
785 785
             $tmpforloop = dolExplodeIntoArray($arrayofxaxis[$val]['tablefromt'], ',');
786 786
             foreach ($tmpforloop as $tmptable => $tmptablealias) {
787
-                if (! in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
787
+                if (!in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
788 788
                     $tmpforexplode = explode('__', $tmptablealias);
789 789
                     $endpart = end($tmpforexplode);
790 790
                     $parenttableandfield = preg_replace('/__' . $endpart . '$/', '', $tmptablealias) . '.' . $endpart;
@@ -811,7 +811,7 @@  discard block
 block discarded – undo
811 811
             //var_dump($arrayofgroupby[$val]); var_dump($tmpval);
812 812
             $tmpforloop = dolExplodeIntoArray($arrayofgroupby[$val]['tablefromt'], ',');
813 813
             foreach ($tmpforloop as $tmptable => $tmptablealias) {
814
-                if (! in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
814
+                if (!in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
815 815
                     $tmpforexplode = explode('__', $tmptablealias);
816 816
                     $endpart = end($tmpforexplode);
817 817
                     $parenttableandfield = preg_replace('/__' . $endpart . '$/', '', $tmptablealias) . '.' . $endpart;
@@ -838,7 +838,7 @@  discard block
 block discarded – undo
838 838
             //var_dump($arrayofgroupby);
839 839
             $tmpforloop = dolExplodeIntoArray($arrayofmesures[$val]['tablefromt'], ',');
840 840
             foreach ($tmpforloop as $tmptable => $tmptablealias) {
841
-                if (! in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
841
+                if (!in_array($tmptable, $listoftablesalreadyadded)) { // We do not add join for main table and tables already added
842 842
                     $tmpforexplode = explode('__', $tmptablealias);
843 843
                     $endpart = end($tmpforexplode);
844 844
                     $parenttableandfield = preg_replace('/__' . $endpart . '$/', '', $tmptablealias) . '.' . $endpart;
Please login to merge, or discard this patch.
htdocs/core/bookmarks_page.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@
 block discarded – undo
71 71
 $title = $langs->trans("Bookmarks");
72 72
 
73 73
 // URL http://mydolibarr/core/bookmarks_page?dol_use_jmobile=1 can be used for tests
74
-$head = '<!-- Bookmarks -->' . "\n";  // This is used by DoliDroid to know page is a bookmark selection page
74
+$head = '<!-- Bookmarks -->' . "\n"; // This is used by DoliDroid to know page is a bookmark selection page
75 75
 $arrayofjs = array();
76 76
 $arrayofcss = array();
77 77
 top_htmlhead($head, $title, 0, 0, $arrayofjs, $arrayofcss);
Please login to merge, or discard this patch.
htdocs/core/login/functions_googleoauth.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -76,10 +76,10 @@
 block discarded – undo
76 76
             //global $dolibarr_main_url_root;
77 77
             //$urlwithouturlroot = preg_replace('/'.preg_quote(DOL_URL_ROOT, '/').'$/i', '', trim($dolibarr_main_url_root));
78 78
             //$urlwithroot = $urlwithouturlroot.DOL_URL_ROOT; // This is to use external domain name found into config file
79
-            $urlwithroot = DOL_MAIN_URL_ROOT;                 // This is to use same domain name than current
79
+            $urlwithroot = DOL_MAIN_URL_ROOT; // This is to use same domain name than current
80 80
 
81 81
             //$shortscope = 'userinfo_email,userinfo_profile';
82
-            $shortscope = 'openid,email,profile';   // For openid connect
82
+            $shortscope = 'openid,email,profile'; // For openid connect
83 83
 
84 84
             $oauthstateanticsrf = bin2hex(random_bytes(128 / 8));
85 85
             $_SESSION['oauthstateanticsrf'] = $shortscope . '-' . $oauthstateanticsrf;
Please login to merge, or discard this patch.
htdocs/core/login/functions_http.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
  */
63 63
 function decodeHttpBasicAuth($value)
64 64
 {
65
-    $encoded_basic_auth = substr($value, 6);    // Remove the "Basic " string
65
+    $encoded_basic_auth = substr($value, 6); // Remove the "Basic " string
66 66
     $decoded_basic_auth = base64_decode($encoded_basic_auth);
67 67
     $credentials_basic_auth = explode(':', $decoded_basic_auth);
68 68
 
Please login to merge, or discard this patch.