Completed
Pull Request — master (#223)
by Philippe
72:43 queued 27:24
created
src/Management/Assistants/PublishAssistant.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 
72 72
     public function findAll(): Collection
73 73
     {
74
-        return $this->model->published()->get()->map(function ($model) {
74
+        return $this->model->published()->get()->map(function($model) {
75 75
             return $this->managers->findByModel($model);
76 76
         });
77 77
     }
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
 
94 94
     public function guard($verb): Assistant
95 95
     {
96
-        if (! $this->can($verb)) {
96
+        if (!$this->can($verb)) {
97 97
             NotAllowedManagerRoute::notAllowedVerb($verb, $this->manager);
98 98
         }
99 99
 
@@ -111,11 +111,11 @@  discard block
 block discarded – undo
111 111
 
112 112
         $class = $this->isPublished() ? 'text-success' : 'text-error';
113 113
 
114
-        $statusAsLabel = '<span class="'. $class .'"><em>' . $label . '</em></span>';
114
+        $statusAsLabel = '<span class="'.$class.'"><em>'.$label.'</em></span>';
115 115
 
116
-        if(!$plain && $this->hasPreviewUrl())
116
+        if (!$plain && $this->hasPreviewUrl())
117 117
         {
118
-            $statusAsLabel =  '<a href="'.$this->previewUrl().'" target="_blank">'. $statusAsLabel .'</a>';
118
+            $statusAsLabel = '<a href="'.$this->previewUrl().'" target="_blank">'.$statusAsLabel.'</a>';
119 119
         }
120 120
 
121 121
         return $statusAsLabel;
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -125,9 +125,9 @@
 block discarded – undo
125 125
     {
126 126
         if ($this->isPublished()) {
127 127
             return 'online';
128
-        }elseif ($this->isDraft()) {
128
+        } elseif ($this->isDraft()) {
129 129
             return 'offline';
130
-        }elseif ($this->manager->isAssistedBy('archive') && $this->manager->assistant('archive')->isArchived()) {
130
+        } elseif ($this->manager->isAssistedBy('archive') && $this->manager->assistant('archive')->isArchived()) {
131 131
             return 'gearchiveerd';
132 132
         }
133 133
 
Please login to merge, or discard this patch.
src/Modules/Module.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -63,11 +63,11 @@
 block discarded – undo
63 63
 
64 64
     public static function managedModelKey(): string
65 65
     {
66
-        if(isset(static::$managedModelKey)){
66
+        if (isset(static::$managedModelKey)) {
67 67
             return static::$managedModelKey;
68 68
         }
69 69
 
70
-        throw new \Exception('Missing required static property \'managedModelKey\' on ' . static::class. '.');
70
+        throw new \Exception('Missing required static property \'managedModelKey\' on '.static::class.'.');
71 71
     }
72 72
 
73 73
     /**
Please login to merge, or discard this patch.
src/Pages/Page.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -80,11 +80,11 @@  discard block
 block discarded – undo
80 80
 
81 81
     public static function managedModelKey(): string
82 82
     {
83
-        if(isset(static::$managedModelKey)){
83
+        if (isset(static::$managedModelKey)) {
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 '';
Please login to merge, or discard this patch.