Test Failed
Branch master (0bcebd)
by Burak
05:24
created
database/migrations/2017_06_17_163005_create_invoices_tables.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
     {
16 16
         $tableNames = config('invoice.table_names');
17 17
 
18
-        Schema::create($tableNames['invoices'], function (Blueprint $table) {
18
+        Schema::create($tableNames['invoices'], function(Blueprint $table) {
19 19
             $table->uuid('id')->primary();
20 20
             $table->uuid('related_id');
21 21
             $table->string('related_type');
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
             $table->index(['invoicable_id', 'invoicable_type']);
38 38
         });
39 39
 
40
-        Schema::create($tableNames['invoice_lines'], function (Blueprint $table) {
40
+        Schema::create($tableNames['invoice_lines'], function(Blueprint $table) {
41 41
             $table->uuid('id')->primary();
42 42
             $table->bigInteger('amount')->default(0)->description('in cents, including tax');
43 43
             $table->bigInteger('tax')->default(0)->description('in cents');
Please login to merge, or discard this patch.
src/Providers/InvoiceServiceProvider.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -30,10 +30,10 @@
 block discarded – undo
30 30
         ], 'config');
31 31
 
32 32
         // Publish migrations
33
-         $this->publishes([
34
-             __DIR__ . '/../../database/migrations/2017_06_17_163005_create_invoices_tables.php'
35
-             => database_path('migrations/2017_06_17_163005_create_invoices_tables.php'),
36
-         ], 'migrations');
33
+            $this->publishes([
34
+                __DIR__ . '/../../database/migrations/2017_06_17_163005_create_invoices_tables.php'
35
+                => database_path('migrations/2017_06_17_163005_create_invoices_tables.php'),
36
+            ], 'migrations');
37 37
 
38 38
         $this->app->bind(InvoiceServiceInterface::class, function ($app) {
39 39
             return new InvoiceService();
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -35,10 +35,10 @@
 block discarded – undo
35 35
              => database_path('migrations/2017_06_17_163005_create_invoices_tables.php'),
36 36
          ], 'migrations');
37 37
 
38
-        $this->app->bind(InvoiceServiceInterface::class, function ($app) {
38
+        $this->app->bind(InvoiceServiceInterface::class, function($app) {
39 39
             return new InvoiceService();
40 40
         });
41
-        $this->app->bind(BillServiceInterface::class, function ($app) {
41
+        $this->app->bind(BillServiceInterface::class, function($app) {
42 42
             return new BillService();
43 43
         });
44 44
     }
Please login to merge, or discard this patch.
src/MoneyFormatter.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -64,11 +64,11 @@
 block discarded – undo
64 64
         return (string) $this->currency;
65 65
     }
66 66
 
67
-     /**
68
-     * Sets the current currency
69
-     * @param $currency The currency (i.e. 'EUR')
70
-     * @return Void
71
-     */
67
+        /**
68
+         * Sets the current currency
69
+         * @param $currency The currency (i.e. 'EUR')
70
+         * @return Void
71
+         */
72 72
     public function setCurrency(string $currency)
73 73
     {
74 74
         $this->currency = $currency;
Please login to merge, or discard this patch.
src/Services/BillService.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -176,9 +176,9 @@
 block discarded – undo
176 176
         $free          = $lines->where('is_free', true)->toBase();
177 177
         $complimentary = $lines->where('is_complimentary', true)->toBase();
178 178
         $other         = $lines
179
-                                       ->where('is_free', false)
180
-                                       ->where('is_complimentary', false)
181
-                                       ->toBase();
179
+                                        ->where('is_free', false)
180
+                                        ->where('is_complimentary', false)
181
+                                        ->toBase();
182 182
 
183 183
         $this->bill->total    = $other->sum('amount');
184 184
         $this->bill->tax      = $other->sum('tax');
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -212,11 +212,11 @@  discard block
 block discarded – undo
212 212
      */
213 213
     public function pdf(array $data = []): string
214 214
     {
215
-        if (! defined('DOMPDF_ENABLE_AUTOLOAD')) {
215
+        if (!defined('DOMPDF_ENABLE_AUTOLOAD')) {
216 216
             define('DOMPDF_ENABLE_AUTOLOAD', false);
217 217
         }
218 218
 
219
-        if (file_exists($configPath = base_path().'/vendor/dompdf/dompdf/dompdf_config.inc.php')) {
219
+        if (file_exists($configPath = base_path() . '/vendor/dompdf/dompdf/dompdf_config.inc.php')) {
220 220
             require_once $configPath;
221 221
         }
222 222
 
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
 
236 236
         return new Response($this->pdf($data), 200, [
237 237
             'Content-Description' => 'File Transfer',
238
-            'Content-Disposition' => 'attachment; filename="'.$filename.'"',
238
+            'Content-Disposition' => 'attachment; filename="' . $filename . '"',
239 239
             'Content-Transfer-Encoding' => 'binary',
240 240
             'Content-Type' => 'application/pdf',
241 241
         ]);
Please login to merge, or discard this patch.
src/Services/InvoiceService.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -174,8 +174,8 @@
 block discarded – undo
174 174
         $free          = $lines->where('is_free', true)->toBase();
175 175
         $complimentary = $lines->where('is_complimentary', true)->toBase();
176 176
         $other         = $lines->where('is_free', false)
177
-                               ->where('is_complimentary', false)
178
-                               ->toBase();
177
+                                ->where('is_complimentary', false)
178
+                                ->toBase();
179 179
 
180 180
         $this->invoice->total    = $other->sum('amount');
181 181
         $this->invoice->tax      = $other->sum('tax');
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -212,11 +212,11 @@  discard block
 block discarded – undo
212 212
      */
213 213
     public function pdf(array $data = []): string
214 214
     {
215
-        if (! defined('DOMPDF_ENABLE_AUTOLOAD')) {
215
+        if (!defined('DOMPDF_ENABLE_AUTOLOAD')) {
216 216
             define('DOMPDF_ENABLE_AUTOLOAD', false);
217 217
         }
218 218
 
219
-        if (file_exists($configPath = base_path().'/vendor/dompdf/dompdf/dompdf_config.inc.php')) {
219
+        if (file_exists($configPath = base_path() . '/vendor/dompdf/dompdf/dompdf_config.inc.php')) {
220 220
             require_once $configPath;
221 221
         }
222 222
 
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
 
236 236
         return new Response($this->pdf($data), 200, [
237 237
             'Content-Description' => 'File Transfer',
238
-            'Content-Disposition' => 'attachment; filename="'.$filename.'"',
238
+            'Content-Disposition' => 'attachment; filename="' . $filename . '"',
239 239
             'Content-Transfer-Encoding' => 'binary',
240 240
             'Content-Type' => 'application/pdf',
241 241
         ]);
Please login to merge, or discard this patch.
src/Models/Bill.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
     {
21 21
         parent::boot();
22 22
         static::addGlobalScope(new BillScope());
23
-        static::creating(function ($model) {
23
+        static::creating(function($model) {
24 24
             $model->is_bill = true;
25 25
         });
26 26
     }
Please login to merge, or discard this patch.
src/Models/Invoice.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
      * @var array
20 20
      */
21 21
     protected $fillable = [
22
-        'related_id', 'related_type', 'tax',  'total', 'discount', 'currency',
22
+        'related_id', 'related_type', 'tax', 'total', 'discount', 'currency',
23 23
         'reference', 'status', 'receiver_info', 'sender_info', 'payment_info', 'note', 'is_bill'
24 24
     ];
25 25
 
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
     {
43 43
         parent::boot();
44 44
         static::addGlobalScope(new InvoiceScope());
45
-        static::creating(function ($model) {
45
+        static::creating(function($model) {
46 46
             /**
47 47
              * @var \Illuminate\Database\Eloquent\Model $model
48 48
              */
Please login to merge, or discard this patch.
src/Models/InvoiceLine.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
     protected static function boot()
35 35
     {
36 36
         parent::boot();
37
-        static::creating(function ($model) {
37
+        static::creating(function($model) {
38 38
             /**
39 39
              * @var \Illuminate\Database\Eloquent\Model $model
40 40
              */
Please login to merge, or discard this patch.