Completed
Push — master ( eb5f5d...be126d )
by Andrii
01:38
created
src/models/AssetPackage.php 1 patch
Doc Comments   +17 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,6 +39,9 @@  discard block
 block discarded – undo
39 39
         return strtolower(static::normalizeScopedName($name));
40 40
     }
41 41
 
42
+    /**
43
+     * @return string
44
+     */
42 45
     public static function normalizeScopedName($name)
43 46
     {
44 47
         return preg_replace("#@(.+?)/#", '${1}--', $name);
@@ -73,11 +76,17 @@  discard block
 block discarded – undo
73 76
         return Yii::$app->get('registryFactory');
74 77
     }
75 78
 
79
+    /**
80
+     * @param string $type
81
+     */
76 82
     public function checkType($type)
77 83
     {
78 84
         return $type === 'bower' || $type === 'npm';
79 85
     }
80 86
 
87
+    /**
88
+     * @param string $name
89
+     */
81 90
     public function checkName($name)
82 91
     {
83 92
         return strlen($name) > 0;
@@ -88,6 +97,10 @@  discard block
 block discarded – undo
88 97
         return static::buildFullName($this->_type, $this->_name);
89 98
     }
90 99
 
100
+    /**
101
+     * @param string $type
102
+     * @param string $name
103
+     */
91 104
     public static function buildNormalName($type, $name)
92 105
     {
93 106
         return static::buildFullName($type, static::normalizeName($name));
@@ -222,6 +235,9 @@  discard block
 block discarded – undo
222 235
         return $releases;
223 236
     }
224 237
 
238
+    /**
239
+     * @param string $version
240
+     */
225 241
     protected function prepareVersion($version)
226 242
     {
227 243
         if ($this->getNormalName() === 'bower-asset/angular') {
@@ -328,7 +344,7 @@  discard block
 block discarded – undo
328 344
     }
329 345
 
330 346
     /**
331
-     * @return array
347
+     * @return string[]
332 348
      */
333 349
     public function __sleep()
334 350
     {
Please login to merge, or discard this patch.