Completed
Pull Request — 3.x (#4591)
by Chris
03:22
created
Tests/Fixtures/Admin/PostAdmin.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -8,6 +8,9 @@
 block discarded – undo
8 8
 {
9 9
     protected $metadataClass = null;
10 10
 
11
+    /**
12
+     * @param string $associationMapping
13
+     */
11 14
     public function setParentAssociationMapping($associationMapping)
12 15
     {
13 16
         $this->parentAssociationMapping = $associationMapping;
Please login to merge, or discard this patch.
Tests/Helpers/PHPUnit_Framework_TestCase.php 1 patch
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -22,6 +22,7 @@
 block discarded – undo
22 22
 {
23 23
     /**
24 24
      * {@inheritdoc}
25
+     * @param string $exception
25 26
      */
26 27
     public function expectException($exception, $message = '', $code = null)
27 28
     {
Please login to merge, or discard this patch.
Tests/Show/ShowMapperTest.php 1 patch
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -450,6 +450,10 @@
 block discarded – undo
450 450
         $this->showMapper = new ShowMapper($this->showBuilder, $this->fieldDescriptionCollection, $this->admin);
451 451
     }
452 452
 
453
+    /**
454
+     * @param string $name
455
+     * @param string $label
456
+     */
453 457
     private function getFieldDescriptionMock($name = null, $label = null)
454 458
     {
455 459
         $fieldDescription = $this->getMockForAbstractClass('Sonata\AdminBundle\Admin\BaseFieldDescription');
Please login to merge, or discard this patch.
Twig/GlobalVariables.php 1 patch
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
     /**
67 67
      * @param string $code
68 68
      * @param string $action
69
-     * @param array  $parameters
69
+     * @param string[]  $parameters
70 70
      * @param mixed  $absolute
71 71
      *
72 72
      * @return string
@@ -81,8 +81,8 @@  discard block
 block discarded – undo
81 81
     /**
82 82
      * @param string $code
83 83
      * @param string $action
84
-     * @param mixed  $object
85
-     * @param array  $parameters
84
+     * @param string  $object
85
+     * @param string[]  $parameters
86 86
      * @param mixed  $absolute
87 87
      *
88 88
      * @return string
@@ -95,8 +95,8 @@  discard block
 block discarded – undo
95 95
     }
96 96
 
97 97
     /**
98
-     * @param $code
99
-     * @param $action
98
+     * @param string $code
99
+     * @param string $action
100 100
      *
101 101
      * @return array
102 102
      */
Please login to merge, or discard this patch.
Twig/Extension/SonataAdminExtension.php 1 patch
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     /**
124 124
      * render a list element from the FieldDescription.
125 125
      *
126
-     * @param mixed                     $object
126
+     * @param \stdClass                     $object
127 127
      * @param FieldDescriptionInterface $fieldDescription
128 128
      * @param array                     $params
129 129
      *
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
      * render a view element.
227 227
      *
228 228
      * @param FieldDescriptionInterface $fieldDescription
229
-     * @param mixed                     $object
229
+     * @param \stdClass                     $object
230 230
      *
231 231
      * @return string
232 232
      */
@@ -365,7 +365,7 @@  discard block
 block discarded – undo
365 365
     /**
366 366
      * Get the identifiers as a string that is safe to use in a url.
367 367
      *
368
-     * @param object         $model
368
+     * @param \stdClass         $model
369 369
      * @param AdminInterface $admin
370 370
      *
371 371
      * @return string string representation of the id that is safe to use in a url
@@ -390,7 +390,7 @@  discard block
 block discarded – undo
390 390
     /**
391 391
      * @param $type
392 392
      *
393
-     * @return string|bool
393
+     * @return string|false
394 394
      */
395 395
     public function getXEditableType($type)
396 396
     {
@@ -447,7 +447,7 @@  discard block
 block discarded – undo
447 447
      * @param FieldDescriptionInterface $fieldDescription
448 448
      * @param string                    $defaultTemplate
449 449
      *
450
-     * @return \Twig_TemplateInterface
450
+     * @return \Twig_Template
451 451
      */
452 452
     protected function getTemplate(
453 453
         FieldDescriptionInterface $fieldDescription,
Please login to merge, or discard this patch.
Tests/Fixtures/Admin/CommentAdmin.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -7,6 +7,9 @@  discard block
 block discarded – undo
7 7
 
8 8
 class CommentAdmin extends AbstractAdmin
9 9
 {
10
+    /**
11
+     * @param string $label
12
+     */
10 13
     public function setClassnameLabel($label)
11 14
     {
12 15
         $this->classnameLabel = $label;
@@ -17,6 +20,9 @@  discard block
 block discarded – undo
17 20
         $collection->remove('edit');
18 21
     }
19 22
 
23
+    /**
24
+     * @param string $associationMapping
25
+     */
20 26
     public function setParentAssociationMapping($associationMapping)
21 27
     {
22 28
         $this->parentAssociationMapping = $associationMapping;
Please login to merge, or discard this patch.
Tests/Fixtures/Admin/CommentWithCustomRouteAdmin.php 1 patch
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -2,9 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace Sonata\AdminBundle\Tests\Fixtures\Admin;
4 4
 
5
-use Sonata\AdminBundle\Admin\AbstractAdmin;
6
-use Sonata\AdminBundle\Route\RouteCollection;
7
-
8 5
 class CommentWithCustomRouteAdmin extends CommentAdmin
9 6
 {
10 7
     protected $baseRoutePattern = 'comment-custom';
Please login to merge, or discard this patch.
Controller/CRUDController.php 1 patch
Doc Comments   +6 added lines, -5 removed lines patch added patch discarded remove patch
@@ -58,6 +58,7 @@  discard block
 block discarded – undo
58 58
 
59 59
     /**
60 60
      * {@inheritdoc}
61
+     * @param null|string $view
61 62
      */
62 63
     public function render($view, array $parameters = [], Response $response = null)
63 64
     {
@@ -154,7 +155,7 @@  discard block
 block discarded – undo
154 155
     /**
155 156
      * Delete action.
156 157
      *
157
-     * @param int|string|null $id
158
+     * @param integer|null $id
158 159
      *
159 160
      * @return Response|RedirectResponse
160 161
      *
@@ -673,7 +674,7 @@  discard block
 block discarded – undo
673 674
     /**
674 675
      * View history revision of object.
675 676
      *
676
-     * @param int|string|null $id
677
+     * @param null|integer $id
677 678
      * @param string|null     $revision
678 679
      *
679 680
      * @return Response
@@ -733,9 +734,9 @@  discard block
 block discarded – undo
733 734
     /**
734 735
      * Compare history revisions of object.
735 736
      *
736
-     * @param int|string|null $id
737
-     * @param int|string|null $base_revision
738
-     * @param int|string|null $compare_revision
737
+     * @param null|integer $id
738
+     * @param null|integer $base_revision
739
+     * @param null|integer $compare_revision
739 740
      *
740 741
      * @return Response
741 742
      *
Please login to merge, or discard this patch.
Tests/Controller/CRUDControllerTest.php 1 patch
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -3759,6 +3759,9 @@  discard block
 block discarded – undo
3759 3759
         ];
3760 3760
     }
3761 3761
 
3762
+    /**
3763
+     * @param string $method
3764
+     */
3762 3765
     private function assertLoggerLogsModelManagerException($subject, $method)
3763 3766
     {
3764 3767
         $exception = new ModelManagerException(
@@ -3781,6 +3784,10 @@  discard block
 block discarded – undo
3781 3784
             ]);
3782 3785
     }
3783 3786
 
3787
+    /**
3788
+     * @param string $id
3789
+     * @param string $domain
3790
+     */
3784 3791
     private function expectTranslate($id, array $parameters = [], $domain = null, $locale = null)
3785 3792
     {
3786 3793
         $this->translator->expects($this->once())
Please login to merge, or discard this patch.