Completed
Pull Request — master (#351)
by Philippe
69:08 queued 21:05
created
src/Pages/Page.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
             return static::$managedModelKey;
85 85
         }
86 86
 
87
-        throw new \Exception('Missing required static property \'managedModelKey\' on ' . static::class. '.');
87
+        throw new \Exception('Missing required static property \'managedModelKey\' on '.static::class.'.');
88 88
     }
89 89
 
90 90
     /**
@@ -124,9 +124,9 @@  discard block
 block discarded – undo
124 124
     public function flatReferenceLabel(): string
125 125
     {
126 126
         if ($this->exists) {
127
-            $status = ! $this->isPublished() ? ' [' . $this->statusAsPlainLabel().']' : null;
127
+            $status = !$this->isPublished() ? ' ['.$this->statusAsPlainLabel().']' : null;
128 128
 
129
-            return $this->title ? $this->title . $status : '';
129
+            return $this->title ? $this->title.$status : '';
130 130
         }
131 131
 
132 132
         return '';
@@ -136,8 +136,8 @@  discard block
 block discarded – undo
136 136
     {
137 137
         $classKey = get_class($this);
138 138
         if (property_exists($this, 'labelSingular')) {
139
-            $labelSingular =  $this->labelSingular;
140
-        } else {
139
+            $labelSingular = $this->labelSingular;
140
+        }else {
141 141
             $labelSingular = Str::singular($classKey);
142 142
         }
143 143
 
Please login to merge, or discard this patch.
src/Fields/Types/MediaField.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types = 1);
3
+declare(strict_types=1);
4 4
 
5 5
 namespace Thinktomorrow\Chief\Fields\Types;
6 6
 
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
             return $this;
41 41
         }
42 42
 
43
-        return 'files['. ($this->values['name'] ?? $this->key()).']';
43
+        return 'files['.($this->values['name'] ?? $this->key()).']';
44 44
     }
45 45
 
46 46
     public function sluggifyName()
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
         $images = [];
59 59
         $locale = $locale ?? app()->getLocale();
60 60
 
61
-        $assets = $model->assetRelation->where('pivot.type', $this->key())->filter(function ($asset) use ($locale) {
61
+        $assets = $model->assetRelation->where('pivot.type', $this->key())->filter(function($asset) use ($locale) {
62 62
             return $asset->pivot->locale == $locale;
63 63
         })->sortBy('pivot.order');
64 64
 
Please login to merge, or discard this patch.