Passed
Push — master ( 99708e...74870e )
by Thomas
14:05
created
app/Console/Commands/fixIncorrectProductTypesCommand.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
         foreach (Invoice::with('invoiceDetails')->get() as $invoice) {
22 22
             // Supprimer les factures qui ne correspondent à rien (souvent des doublons générés en cas d'erreurs dans la transmission à Ecuasolutions.
23 23
             if ($invoice->enrollments->count() > 0 && DB::table('enrollment_invoice')->where('invoice_id', $invoice->id)->count() === 0) {
24
-                 DB::table('invoices')->where('id', $invoice->id)->delete();
24
+                    DB::table('invoices')->where('id', $invoice->id)->delete();
25 25
                 echo "\n facture # $invoice->id supprimée";
26 26
             }
27 27
         }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 
37 37
                     if ($invoiceDetail) {
38 38
                         $invoiceDetail->update([
39
-                            'product_name' => 'Inscription # ' . $enrollment->id,
39
+                            'product_name' => 'Inscription # '.$enrollment->id,
40 40
                             'product_code' => '',
41 41
                             'product_id' => $enrollment->id,
42 42
                             'product_type' => Enrollment::class,
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
                     } else {
47 47
                         InvoiceDetail::create([
48 48
                             'invoice_id' => $invoice->id,
49
-                            'product_name' => 'Inscription # ' . $enrollment->id,
49
+                            'product_name' => 'Inscription # '.$enrollment->id,
50 50
                             'product_code' => '',
51 51
                             'product_id' => $enrollment->id,
52 52
                             'product_type' => Enrollment::class,
Please login to merge, or discard this patch.