Passed
Push — master ( 5b7473...eb3d65 )
by Andreas
26:40
created
lib/org/openpsa/sales/salesproject/deliverable.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
     {
79 79
         $this->calculate_price(false);
80 80
 
81
-        if (   $this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
81
+        if ($this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
82 82
             && $this->continuous) {
83 83
             $this->end = 0;
84 84
         } elseif ($this->end < $this->start) {
@@ -166,7 +166,7 @@  discard block
 block discarded – undo
166 166
         $calculator->run($this);
167 167
         $cost = $calculator->get_cost();
168 168
         $price = $calculator->get_price();
169
-        if (   $price != $this->price
169
+        if ($price != $this->price
170 170
             || $cost != $this->cost) {
171 171
             $this->price = $price;
172 172
             $this->cost = $cost;
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
         $units = $agreement_hours['invoiceable'];
214 214
         $uninvoiceableUnits = $agreement_hours['reported'] - ($agreement_hours['invoiceable'] + $agreement_hours['invoiced']);
215 215
 
216
-        if (   $units != $this->units
216
+        if ($units != $this->units
217 217
             || $uninvoiceableUnits != $this->uninvoiceableUnits) {
218 218
             debug_add("agreement values have changed, setting units to " . $units . ", uninvoiceable: " . $uninvoiceableUnits);
219 219
             $this->units = $units;
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
 
268 268
     public function invoice() : bool
269 269
     {
270
-        if (   $this->state >= self::STATE_INVOICED
270
+        if ($this->state >= self::STATE_INVOICED
271 271
             || $this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION) {
272 272
             return false;
273 273
         }
@@ -370,7 +370,7 @@  discard block
 block discarded – undo
370 370
             midcom::get()->uimessages->add(midcom::get()->i18n->get_string('org.openpsa.sales', 'org.openpsa.sales'), sprintf(midcom::get()->i18n->get_string('marked deliverable "%s" delivered', 'org.openpsa.sales'), $this->title));
371 371
 
372 372
             // Check if we need to create task or ship goods
373
-            if (   $update_deliveries
373
+            if ($update_deliveries
374 374
                 && $product->orgOpenpsaObtype === org_openpsa_products_product_dba::TYPE_SERVICE) {
375 375
                 // Change status of tasks connected to the deliverable
376 376
                 $qb = org_openpsa_projects_task_dba::new_query_builder();
Please login to merge, or discard this patch.