Test Setup Failed
Branch master (95afbf)
by Eugene
04:58
created
src/Acl/AclService.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@
 block discarded – undo
66 66
 
67 67
     /**
68 68
      * @param array $options
69
-     * @param mixed $option
69
+     * @param string $option
70 70
      * @param mixed $default
71 71
      * @return array
72 72
      */
Please login to merge, or discard this patch.
src/Auth/SaveHandlers/Redis.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -155,7 +155,7 @@
 block discarded – undo
155 155
 
156 156
     /**
157 157
      * Add prefix for session's key
158
-     * @param $sessionId
158
+     * @param string $sessionId
159 159
      * @return string
160 160
      */
161 161
     protected function getSessionKey($sessionId)
Please login to merge, or discard this patch.
src/Middlewares/ActionGetAbstract.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
     }
50 50
 
51 51
     /**
52
-     * @param $path
52
+     * @param string $path
53 53
      * @param string $filename Filename for saving dialog on the client-side
54 54
      * @param bool $forceSaveDialog
55 55
      * @return EmptyResponse
Please login to merge, or discard this patch.
src/Middlewares/ActionPostAbstract.php 2 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
     }
103 103
 
104 104
     /**
105
-     * @return string|null
105
+     * @return UploadedFile|null
106 106
      */
107 107
     protected function upload()
108 108
     {
@@ -118,8 +118,8 @@  discard block
 block discarded – undo
118 118
 
119 119
     /**
120 120
      * @param ResourceDOInterface $resourceDO
121
-     * @param $uri
122
-     * @return UploadedFile
121
+     * @param string $uri
122
+     * @return DownloadedFile
123 123
      * @throws ErrorException
124 124
      * @throws \Exception
125 125
      */
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -131,11 +131,11 @@
 block discarded – undo
131 131
         set_time_limit(self::CURL_TIMEOUT);
132 132
         $dir = DATA_DIR . 'download' . DIRECTORY_SEPARATOR;
133 133
         $file = $this->resourceDO->getUuid() . '_' . time() . '_' . mt_rand(100, 200) . '.tmp';
134
-        if(!@mkdir($dir) && !is_dir($dir)) {
134
+        if (!@mkdir($dir) && !is_dir($dir)) {
135 135
             throw new ErrorException('Can\'t create the directory: ' . $dir);
136 136
         }
137 137
         if (is_file($file)) {
138
-            if(!unlink($file)) {
138
+            if (!unlink($file)) {
139 139
                 throw new ErrorException('Can\'t remove old file: ' . $dir . $file);
140 140
             }
141 141
         }
Please login to merge, or discard this patch.
src/Resources/Middlewares/Image/ImagePostProcessingMiddlewareAbstract.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@
 block discarded – undo
52 52
     }
53 53
 
54 54
     /**
55
-     * @param $directory
55
+     * @param string $directory
56 56
      * @throws SaveResourceErrorException
57 57
      * @see \Staticus\Resources\Middlewares\SaveResourceMiddlewareAbstract::createDirectory
58 58
      */
Please login to merge, or discard this patch.
src/Resources/Middlewares/PrepareResourceMiddlewareAbstract.php 1 patch
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -96,6 +96,9 @@  discard block
 block discarded – undo
96 96
     }
97 97
     abstract protected function fillResourceSpecialFields();
98 98
 
99
+    /**
100
+     * @param string $name
101
+     */
99 102
     protected function cleanup($name)
100 103
     {
101 104
         $name = preg_replace('/\s+/u', ' ', trim(mb_strtolower(rawurldecode((string)$name), 'UTF-8')));
@@ -131,6 +134,10 @@  discard block
 block discarded – undo
131 134
         return $str;
132 135
     }
133 136
 
137
+    /**
138
+     * @param string $name
139
+     * @param string $value
140
+     */
134 141
     protected function defaultValidator($name, $value, $canBeEmpty = false, $allowedRegexpSymbols = '\w\d\-_', $replaceDeniedSymbols = false)
135 142
     {
136 143
         if (!empty($value)) {
Please login to merge, or discard this patch.
src/Resources/Middlewares/SaveResourceMiddlewareAbstract.php 1 patch
Doc Comments   +9 added lines, -2 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     }
83 83
 
84 84
     /**
85
-     * @param $filePath
85
+     * @param string $filePath
86 86
      * @param $content
87 87
      */
88 88
     protected function writeFile($filePath, $content)
@@ -97,6 +97,10 @@  discard block
 block discarded – undo
97 97
         }
98 98
     }
99 99
 
100
+    /**
101
+     * @param string $mime
102
+     * @param string $filePath
103
+     */
100 104
     protected function uploadFile(UploadedFileInterface $content, $mime, $filePath)
101 105
     {
102 106
         $uri = $content->getStream()->getMetadata('uri');
@@ -123,7 +127,7 @@  discard block
 block discarded – undo
123 127
     }
124 128
 
125 129
     /**
126
-     * @param $directory
130
+     * @param string $directory
127 131
      * @throws SaveResourceErrorException
128 132
      * @see \Staticus\Resources\Middlewares\Image\ImagePostProcessingMiddlewareAbstract::createDirectory
129 133
      */
@@ -190,6 +194,9 @@  discard block
 block discarded – undo
190 194
     }
191 195
     abstract protected function afterSave(ResourceDOInterface $resourceDO);
192 196
 
197
+    /**
198
+     * @return ResourceDOInterface
199
+     */
193 200
     protected function backup(ResourceDOInterface $resourceDO)
194 201
     {
195 202
         $command = new BackupResourceCommand($resourceDO, $this->filesystem);
Please login to merge, or discard this patch.
src/test/Resources/Commands/AddWrongFilesToDiskTrait.php 1 patch
Doc Comments   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
     /**
9 9
      * Put bad files to the 'disk'
10 10
      * @param $resourceDO
11
-     * @param $content
11
+     * @param string $content
12 12
      * @return string
13 13
      */
14 14
     protected function addWrongFilesToDisk(ResourceDOInterface $resourceDO, $content)
@@ -44,6 +44,9 @@  discard block
 block discarded – undo
44 44
         $this->assertTrue($this->filesystem->has($filePath));
45 45
     }
46 46
 
47
+    /**
48
+     * @param \Staticus\Resources\File\ResourceDO $resourceDO
49
+     */
47 50
     protected function assertWrongFilesIsStillHere($resourceDO)
48 51
     {
49 52
         $resourceDO = clone $resourceDO;
Please login to merge, or discard this patch.
src/test/Resources/Commands/CopyResourceCommandTest.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
     }
25 25
 
26 26
     /**
27
-     * @return BackupResourceCommand
27
+     * @return CopyResourceCommand
28 28
      */
29 29
     public function getCommand(ResourceDO $resourceDOSource, ResourceDO $resourceDODest)
30 30
     {
Please login to merge, or discard this patch.