@@ -410,7 +410,7 @@ |
||
| 410 | 410 | * |
| 411 | 411 | * @param Mixed $needle the needle. |
| 412 | 412 | * @param array $haystack the haystack. |
| 413 | - * @return is the needle not in the haystack? |
|
| 413 | + * @return boolean the needle not in the haystack? |
|
| 414 | 414 | */ |
| 415 | 415 | protected function negative_in_array( $needle, $haystack ) { |
| 416 | 416 | if ( in_array( $needle, $haystack, true ) ) { |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | * |
| 19 | 19 | * @param string $access_token The Instagram access token. |
| 20 | 20 | * @param int $count The number of Instagram posts to fetch. |
| 21 | - * @return mixed |
|
| 21 | + * @return integer|null |
|
| 22 | 22 | */ |
| 23 | 23 | public static function get_instagram_gallery( $access_token, $count ) { |
| 24 | 24 | $site_id = self::get_site_id(); |
@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | * |
| 39 | 39 | * A null argument will log the file and line number of the l() call. |
| 40 | 40 | * |
| 41 | - * @param mixed $stuff Information to log. |
|
| 41 | + * @param string $stuff Information to log. |
|
| 42 | 42 | */ |
| 43 | 43 | function l( $stuff = null ) { |
| 44 | 44 | // Do nothing when debugging is off. |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | * |
| 167 | 167 | * @param string $name Timer name. |
| 168 | 168 | * |
| 169 | - * @return mixed void or elapsed time. |
|
| 169 | + * @return null|double void or elapsed time. |
|
| 170 | 170 | */ |
| 171 | 171 | function e( $name = '' ) { |
| 172 | 172 | static $times = array(); |
@@ -433,6 +433,9 @@ |
||
| 433 | 433 | ); |
| 434 | 434 | } |
| 435 | 435 | |
| 436 | + /** |
|
| 437 | + * @param string $column |
|
| 438 | + */ |
|
| 436 | 439 | function _build_date_range_query( $column, $range, $where ) { |
| 437 | 440 | global $wpdb; |
| 438 | 441 | |
@@ -15,6 +15,9 @@ |
||
| 15 | 15 | exit; |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | +/** |
|
| 19 | + * @param string $file_pattern |
|
| 20 | + */ |
|
| 18 | 21 | function wpcom_rest_api_v2_load_plugin_files( $file_pattern ) { |
| 19 | 22 | $plugins = glob( dirname( __FILE__ ) . '/' . $file_pattern ); |
| 20 | 23 | |
@@ -42,7 +42,7 @@ discard block |
||
| 42 | 42 | /** |
| 43 | 43 | * Singleton implementation |
| 44 | 44 | * |
| 45 | - * @return object |
|
| 45 | + * @return Jetpack_Photon|null |
|
| 46 | 46 | */ |
| 47 | 47 | public static function instance() { |
| 48 | 48 | if ( ! is_a( self::$instance, 'Jetpack_Photon' ) ) { |
@@ -1382,7 +1382,7 @@ discard block |
||
| 1382 | 1382 | * after ourselves without breaking anyone else's filters. |
| 1383 | 1383 | * |
| 1384 | 1384 | * @internal |
| 1385 | - * @return true |
|
| 1385 | + * @return boolean |
|
| 1386 | 1386 | */ |
| 1387 | 1387 | public function override_image_downsize_in_rest_edit_context() { |
| 1388 | 1388 | return true; |
@@ -583,7 +583,7 @@ discard block |
||
| 583 | 583 | * Only enqueue block assets when needed. |
| 584 | 584 | * |
| 585 | 585 | * @param string $type Slug of the block. |
| 586 | - * @param array $script_dependencies Script dependencies. Will be merged with automatically |
|
| 586 | + * @param string[] $script_dependencies Script dependencies. Will be merged with automatically |
|
| 587 | 587 | * detected script dependencies from the webpack build. |
| 588 | 588 | * |
| 589 | 589 | * @return void |
@@ -837,7 +837,7 @@ discard block |
||
| 837 | 837 | * |
| 838 | 838 | * @param string $slug Block slug. |
| 839 | 839 | * @param array $attr Block attributes. |
| 840 | - * @param array $extra Potential extra classes you may want to provide. |
|
| 840 | + * @param string[] $extra Potential extra classes you may want to provide. |
|
| 841 | 841 | * |
| 842 | 842 | * @return string $classes List of CSS classes for a block. |
| 843 | 843 | */ |
@@ -934,10 +934,10 @@ discard block |
||
| 934 | 934 | * @since 8.3.0 |
| 935 | 935 | * |
| 936 | 936 | * @param string $url URL saved as an attribute in block. |
| 937 | - * @param array $allowed Array of allowed hosts for that block, or regexes to check against. |
|
| 937 | + * @param string[] $allowed Array of allowed hosts for that block, or regexes to check against. |
|
| 938 | 938 | * @param bool $is_regex Array of regexes matching the URL that could be used in block. |
| 939 | 939 | * |
| 940 | - * @return bool|string |
|
| 940 | + * @return false|string |
|
| 941 | 941 | */ |
| 942 | 942 | public static function validate_block_embed_url( $url, $allowed = array(), $is_regex = false ) { |
| 943 | 943 | if ( |
@@ -105,7 +105,7 @@ |
||
| 105 | 105 | /** |
| 106 | 106 | * Returns an instance of the Jetpack object. |
| 107 | 107 | * |
| 108 | - * @return Automattic\Jetpack |
|
| 108 | + * @return Jetpack |
|
| 109 | 109 | */ |
| 110 | 110 | public function get_jetpack() { |
| 111 | 111 | return Jetpack::init(); |
@@ -62,6 +62,10 @@ |
||
| 62 | 62 | return $query->is_main_query() && $query->is_search(); |
| 63 | 63 | } |
| 64 | 64 | |
| 65 | + /** |
|
| 66 | + * @param double $duration |
|
| 67 | + * @param boolean $was_jetpack_search |
|
| 68 | + */ |
|
| 65 | 69 | private function record_query_time( $duration, $was_jetpack_search ) { |
| 66 | 70 | $this->stats[] = array( $was_jetpack_search, (int) ( $duration * 1000 ) ); |
| 67 | 71 | } |