Completed
Pull Request — master (#13)
by
unknown
06:10
created
src/Widget/WidgetCollection.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
         }
29 29
 
30 30
         return $this->filter(
31
-            function ($widget) use ($user) {
31
+            function($widget) use ($user) {
32 32
 
33 33
                 /* @var WidgetInterface $widget */
34 34
                 return $user->hasAnyRole($widget->getAllowedRoles());
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
     public function pinned()
46 46
     {
47 47
         return $this->filter(
48
-            function ($widget) {
48
+            function($widget) {
49 49
 
50 50
                 /* @var WidgetInterface $widget */
51 51
                 return $widget->isPinned();
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
     public function column($column, $over = false)
64 64
     {
65 65
         return $this->filter(
66
-            function ($widget) use ($column, $over) {
66
+            function($widget) use ($column, $over) {
67 67
 
68 68
                 /* @var WidgetInterface $widget */
69 69
                 if ($widget->isPinned()) {
Please login to merge, or discard this patch.
src/Widget/Extension/Form/WidgetExtensionFormSections.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -24,20 +24,20 @@
 block discarded – undo
24 24
         $builder->setSections(
25 25
             [
26 26
                 [
27
-                    'fields' => function () use ($widget) {
27
+                    'fields' => function() use ($widget) {
28 28
                         return array_map(
29
-                            function ($field) {
30
-                                return 'widget_' . $field;
29
+                            function($field) {
30
+                                return 'widget_'.$field;
31 31
                             },
32 32
                             $widget->getFormFieldSlugs()
33 33
                         );
34 34
                     }
35 35
                 ],
36 36
                 [
37
-                    'fields' => function () use ($configuration) {
37
+                    'fields' => function() use ($configuration) {
38 38
                         return array_map(
39
-                            function ($field) {
40
-                                return 'configuration_' . $field;
39
+                            function($field) {
40
+                                return 'configuration_'.$field;
41 41
                             },
42 42
                             $configuration->getFormFieldSlugs()
43 43
                         );
Please login to merge, or discard this patch.
src/Http/Controller/Admin/DashboardsController.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
             return $this->redirect->to('admin/dashboard/manage');
35 35
         }
36 36
 
37
-        return $this->redirect->to('admin/dashboard/view/' . $dashboard->getSlug());
37
+        return $this->redirect->to('admin/dashboard/view/'.$dashboard->getSlug());
38 38
     }
39 39
 
40 40
     /**
Please login to merge, or discard this patch.
src/Dashboard/DashboardCollection.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
         }
29 29
 
30 30
         return $this->filter(
31
-            function (DashboardInterface $dashboard) use ($user) {
31
+            function(DashboardInterface $dashboard) use ($user) {
32 32
                 $roles = $dashboard->getAllowedRoles();
33 33
 
34 34
                 return $roles->isEmpty() ?: $user->hasAnyRole($roles);
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
         }
51 51
 
52 52
         return $this->first(
53
-            function (DashboardInterface $model) use ($key) {
53
+            function(DashboardInterface $model) use ($key) {
54 54
                 return $model->getId() == $key || $model->getSlug() == $key;
55 55
             },
56 56
             $default
Please login to merge, or discard this patch.
src/Dashboard/DashboardModel.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,6 @@
 block discarded – undo
3 3
 use Anomaly\DashboardModule\Dashboard\Contract\DashboardInterface;
4 4
 use Anomaly\DashboardModule\Widget\WidgetModel;
5 5
 use Anomaly\Streams\Platform\Model\Dashboard\DashboardDashboardsEntryModel;
6
-use Anomaly\Streams\Platform\Model\EloquentCollection;
7 6
 use Anomaly\UsersModule\Role\RoleCollection;
8 7
 
9 8
 /**
Please login to merge, or discard this patch.
src/Http/Controller/Admin/WidgetsController.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
      * Return the modal for choosing a widget.
36 36
      *
37 37
      * @param  ExtensionCollection                   $extensions
38
-     * @return \Illuminate\Contracts\View\View|mixed
38
+     * @return \Illuminate\Contracts\View\View
39 39
      */
40 40
     public function choose(ExtensionCollection $extensions)
41 41
     {
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
      * Create a new entry.
50 50
      *
51 51
      * @param  ExtensionCollection                          $extensions
52
-     * @param  WidgetExtensionFormBuilder|WidgetFormBuilder $form
52
+     * @param  WidgetExtensionFormBuilder $form
53 53
      * @param  WidgetFormBuilder                            $widget
54 54
      * @param  ConfigurationFormBuilder                     $configuration
55 55
      * @return \Symfony\Component\HttpFoundation\Response
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
      * Edit an existing entry.
74 74
      *
75 75
      * @param  ExtensionCollection                          $extensions
76
-     * @param  WidgetExtensionFormBuilder|WidgetFormBuilder $form
76
+     * @param  WidgetExtensionFormBuilder $form
77 77
      * @param  WidgetFormBuilder                            $widget
78 78
      * @param  ConfigurationFormBuilder                     $configuration
79 79
      * @return \Symfony\Component\HttpFoundation\Response
Please login to merge, or discard this patch.
src/Widget/WidgetModel.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
     /**
102 102
      * Get the data.
103 103
      *
104
-     * @return WidgetData
104
+     * @return WidgetCollection
105 105
      */
106 106
     public function getData()
107 107
     {
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
     /**
148 148
      * Return the widget output.
149 149
      *
150
-     * @return string
150
+     * @return \Illuminate\Contracts\View\View
151 151
      */
152 152
     public function output()
153 153
     {
Please login to merge, or discard this patch.