@@ -22,6 +22,7 @@ discard block |
||
22 | 22 | |
23 | 23 | /** |
24 | 24 | * Scan every PHP in the root |
25 | + * @param string $root |
|
25 | 26 | */ |
26 | 27 | public function scan( $root, $exclude = array() ) { |
27 | 28 | if ( is_dir( $root ) ) { |
@@ -33,6 +34,9 @@ discard block |
||
33 | 34 | } |
34 | 35 | } |
35 | 36 | |
37 | + /** |
|
38 | + * @param string $root |
|
39 | + */ |
|
36 | 40 | public function scan_dir( $root, $exclude = array() ) { |
37 | 41 | |
38 | 42 | if ( is_null( $exclude ) || ! is_array( $exclude ) ) { |
@@ -124,7 +124,7 @@ |
||
124 | 124 | * @param int $cutoff_timestamp All nonces added before this timestamp will be removed. |
125 | 125 | * @param int $time_limit How long the cleanup can run (in seconds). |
126 | 126 | * |
127 | - * @return true |
|
127 | + * @return boolean |
|
128 | 128 | */ |
129 | 129 | public function clean_all( $cutoff_timestamp = PHP_INT_MAX, $time_limit = 20 ) { |
130 | 130 | // phpcs:ignore Generic.CodeAnalysis.ForLoopWithTestFunctionCall.NotAllowed |
@@ -168,7 +168,7 @@ |
||
168 | 168 | /** |
169 | 169 | * Checks to see whether or not the root package is the one that required the autoloader. |
170 | 170 | * |
171 | - * @return bool |
|
171 | + * @return null|boolean |
|
172 | 172 | */ |
173 | 173 | private function isRequiredByRoot() { |
174 | 174 | $package = $this->composer->getPackage(); |
@@ -281,7 +281,7 @@ |
||
281 | 281 | * @param string $password the password. |
282 | 282 | * @param array $test_data the current test data. |
283 | 283 | * |
284 | - * @return bool does the test pass? |
|
284 | + * @return integer does the test pass? |
|
285 | 285 | */ |
286 | 286 | protected function test_preg_match( $password, $test_data ) { |
287 | 287 | return preg_match( $test_data['pattern'], $password ); |
@@ -165,7 +165,7 @@ |
||
165 | 165 | /** |
166 | 166 | * Set the timestamp. |
167 | 167 | * |
168 | - * @param DateTime|string $timestamp Timestamp to set. |
|
168 | + * @param string $timestamp Timestamp to set. |
|
169 | 169 | * @returns $this |
170 | 170 | * @throws InvalidArgumentException If an argument is invalid. |
171 | 171 | */ |
@@ -89,6 +89,7 @@ |
||
89 | 89 | * |
90 | 90 | * @param string $haystack String to split. |
91 | 91 | * @param string[] ...$needles Strings to split on. Earliest match in $haystack wins. |
92 | + * @param string $needles |
|
92 | 93 | * @return string[] Two elements: The part before $needles and the part after, both trimmed. |
93 | 94 | */ |
94 | 95 | private function split( $haystack, ...$needles ) { |
@@ -43,6 +43,7 @@ |
||
43 | 43 | * @param String $action The action name. |
44 | 44 | * @param Integer|bool $user_id The user identifier. Defaults to `false`. |
45 | 45 | * @param Integer $exp Expiration time in seconds. |
46 | + * @return string|boolean |
|
46 | 47 | */ |
47 | 48 | public function generate( $action, $user_id = false, $exp = 600 ) { |
48 | 49 | if ( false === $user_id ) { |
@@ -138,7 +138,7 @@ |
||
138 | 138 | * Extract the index and count from a prerelease string. |
139 | 139 | * |
140 | 140 | * @param string|null $s String. |
141 | - * @return array Two elements: index and count. |
|
141 | + * @return integer[] Two elements: index and count. |
|
142 | 142 | * @throws InvalidArgumentException If the string is invalid. |
143 | 143 | */ |
144 | 144 | private function parsePrerelease( $s ) { |
@@ -290,7 +290,7 @@ discard block |
||
290 | 290 | /** |
291 | 291 | * Verifies the signature of the current request. |
292 | 292 | * |
293 | - * @return false|array |
|
293 | + * @return boolean |
|
294 | 294 | */ |
295 | 295 | public function verify_xml_rpc_signature() { |
296 | 296 | if ( is_null( $this->xmlrpc_verification ) ) { |
@@ -1464,7 +1464,7 @@ discard block |
||
1464 | 1464 | /** |
1465 | 1465 | * Obtains the auth token. |
1466 | 1466 | * |
1467 | - * @param array $data The request data. |
|
1467 | + * @param string $data The request data. |
|
1468 | 1468 | * @return object|\WP_Error Returns the auth token on success. |
1469 | 1469 | * Returns a \WP_Error on failure. |
1470 | 1470 | */ |