Completed
Push — add/wordads ( fe1309...3122c0 )
by
unknown
67:36 queued 56:59
created
class.jetpack.php 1 patch
Doc Comments   +47 added lines, -14 removed lines patch added patch discarded remove patch
@@ -876,7 +876,7 @@  discard block
 block discarded – undo
876 876
 	}
877 877
 	/**
878 878
 	 * Does the network allow admins to add new users.
879
-	 * @return boolian
879
+	 * @return boolean
880 880
 	 */
881 881
 	static function network_add_new_users( $option = null ) {
882 882
 		return (bool) get_site_option( 'add_new_users' );
@@ -976,7 +976,7 @@  discard block
 block discarded – undo
976 976
 	 * database which could be set to anything as opposed to what this function returns.
977 977
 	 * @param  bool  $option
978 978
 	 *
979
-	 * @return boolean
979
+	 * @return string
980 980
 	 */
981 981
 	public function is_main_network_option( $option ) {
982 982
 		// return '1' or ''
@@ -987,7 +987,7 @@  discard block
 block discarded – undo
987 987
 	 * Return true if we are with multi-site or multi-network false if we are dealing with single site.
988 988
 	 *
989 989
 	 * @param  string  $option
990
-	 * @return boolean
990
+	 * @return string
991 991
 	 */
992 992
 	public function is_multisite( $option ) {
993 993
 		return (string) (bool) is_multisite();
@@ -1045,7 +1045,7 @@  discard block
 block discarded – undo
1045 1045
 
1046 1046
 	/**
1047 1047
 	 * Returns true if the site has file write access false otherwise.
1048
-	 * @return string ( '1' | '0' )
1048
+	 * @return integer ( '1' | '0' )
1049 1049
 	 **/
1050 1050
 	public static function file_system_write_access() {
1051 1051
 		if ( ! function_exists( 'get_filesystem_method' ) ) {
@@ -1629,6 +1629,7 @@  discard block
 block discarded – undo
1629 1629
 	* Stores two secrets and a timestamp so WordPress.com can make a request back and verify an action
1630 1630
 	* Does some extra verification so urls (such as those to public-api, register, etc) can't just be crafted
1631 1631
 	* $name must be a registered option name.
1632
+	* @param string $name
1632 1633
 	*/
1633 1634
 	public static function create_nonce( $name ) {
1634 1635
 		$secret = wp_generate_password( 32, false ) . ':' . wp_generate_password( 32, false ) . ':' . ( time() + 600 );
@@ -1686,6 +1687,7 @@  discard block
 block discarded – undo
1686 1687
 	 * @param int $user_id
1687 1688
 	 * @param string $token
1688 1689
 	 * return bool
1690
+	 * @param boolean $is_master_user
1689 1691
 	 */
1690 1692
 	public static function update_user_token( $user_id, $token, $is_master_user ) {
1691 1693
 		// not designed for concurrent updates
@@ -2080,6 +2082,7 @@  discard block
 block discarded – undo
2080 2082
 
2081 2083
 	/**
2082 2084
 	 * Like core's get_file_data implementation, but caches the result.
2085
+	 * @param string $file
2083 2086
 	 */
2084 2087
 	public static function get_file_data( $file, $headers ) {
2085 2088
 		//Get just the filename from $file (i.e. exclude full path) so that a consistent hash is generated
@@ -2108,7 +2111,7 @@  discard block
 block discarded – undo
2108 2111
 	 *
2109 2112
 	 * @param string $tag Tag as it appears in each module heading.
2110 2113
 	 *
2111
-	 * @return mixed
2114
+	 * @return string
2112 2115
 	 */
2113 2116
 	public static function translate_module_tag( $tag ) {
2114 2117
 		return jetpack_get_module_i18n_tag( $tag );
@@ -2121,7 +2124,7 @@  discard block
 block discarded – undo
2121 2124
 	 *
2122 2125
 	 * @param array $modules
2123 2126
 	 *
2124
-	 * @return string|void
2127
+	 * @return string
2125 2128
 	 */
2126 2129
 	public static function get_translated_modules( $modules ) {
2127 2130
 		foreach ( $modules as $index => $module ) {
@@ -2409,6 +2412,9 @@  discard block
 block discarded – undo
2409 2412
 		_deprecated_function( __METHOD__, 'jeptack-4.2' );
2410 2413
 	}
2411 2414
 
2415
+	/**
2416
+	 * @return string
2417
+	 */
2412 2418
 	public static function deactivate_module( $module ) {
2413 2419
 		/**
2414 2420
 		 * Fires when a module is deactivated.
@@ -2437,6 +2443,9 @@  discard block
 block discarded – undo
2437 2443
 		return self::update_active_modules( $new );
2438 2444
 	}
2439 2445
 
2446
+	/**
2447
+	 * @param string $module
2448
+	 */
2440 2449
 	public static function enable_module_configurable( $module ) {
2441 2450
 		$module = Jetpack::get_module_slug( $module );
2442 2451
 		add_filter( 'jetpack_module_configurable_' . $module, '__return_true' );
@@ -2447,21 +2456,33 @@  discard block
 block discarded – undo
2447 2456
 		return Jetpack::admin_url( array( 'page' => 'jetpack', 'configure' => $module ) );
2448 2457
 	}
2449 2458
 
2459
+	/**
2460
+	 * @param string $module
2461
+	 */
2450 2462
 	public static function module_configuration_load( $module, $method ) {
2451 2463
 		$module = Jetpack::get_module_slug( $module );
2452 2464
 		add_action( 'jetpack_module_configuration_load_' . $module, $method );
2453 2465
 	}
2454 2466
 
2467
+	/**
2468
+	 * @param string $module
2469
+	 */
2455 2470
 	public static function module_configuration_head( $module, $method ) {
2456 2471
 		$module = Jetpack::get_module_slug( $module );
2457 2472
 		add_action( 'jetpack_module_configuration_head_' . $module, $method );
2458 2473
 	}
2459 2474
 
2475
+	/**
2476
+	 * @param string $module
2477
+	 */
2460 2478
 	public static function module_configuration_screen( $module, $method ) {
2461 2479
 		$module = Jetpack::get_module_slug( $module );
2462 2480
 		add_action( 'jetpack_module_configuration_screen_' . $module, $method );
2463 2481
 	}
2464 2482
 
2483
+	/**
2484
+	 * @param string $module
2485
+	 */
2465 2486
 	public static function module_configuration_activation_screen( $module, $method ) {
2466 2487
 		$module = Jetpack::get_module_slug( $module );
2467 2488
 		add_action( 'display_activate_module_setting_' . $module, $method );
@@ -2469,6 +2490,9 @@  discard block
 block discarded – undo
2469 2490
 
2470 2491
 /* Installation */
2471 2492
 
2493
+	/**
2494
+	 * @param string $message
2495
+	 */
2472 2496
 	public static function bail_on_activation( $message, $deactivate = true ) {
2473 2497
 ?>
2474 2498
 <!doctype html>
@@ -3097,7 +3121,7 @@  discard block
 block discarded – undo
3097 3121
 	 * Add help to the Jetpack page
3098 3122
 	 *
3099 3123
 	 * @since Jetpack (1.2.3)
3100
-	 * @return false if not the Jetpack page
3124
+	 * @return false|null if not the Jetpack page
3101 3125
 	 */
3102 3126
 	function admin_help() {
3103 3127
 		$current_screen = get_current_screen();
@@ -4122,6 +4146,7 @@  discard block
 block discarded – undo
4122 4146
 	/**
4123 4147
 	 * Returns the requested Jetpack API URL
4124 4148
 	 *
4149
+	 * @param string $relative_url
4125 4150
 	 * @return string
4126 4151
 	 */
4127 4152
 	public static function api_url( $relative_url ) {
@@ -4266,7 +4291,8 @@  discard block
 block discarded – undo
4266 4291
 	 * Note these tokens are unique per call, NOT static per site for connecting.
4267 4292
 	 *
4268 4293
 	 * @since 2.6
4269
-	 * @return array
4294
+	 * @param string $action
4295
+	 * @return string
4270 4296
 	 */
4271 4297
 	public function generate_secrets( $action, $exp = 600 ) {
4272 4298
 	    $secret = wp_generate_password( 32, false ) // secret_1
@@ -4592,6 +4618,10 @@  discard block
 block discarded – undo
4592 4618
 		return new WP_User( $token_details['user_id'] );
4593 4619
 	}
4594 4620
 
4621
+	/**
4622
+	 * @param integer $timestamp
4623
+	 * @param string $nonce
4624
+	 */
4595 4625
 	function add_nonce( $timestamp, $nonce ) {
4596 4626
 		global $wpdb;
4597 4627
 		static $nonces_used_this_request = array();
@@ -4737,6 +4767,7 @@  discard block
 block discarded – undo
4737 4767
 	 * @param string $key
4738 4768
 	 * @param string $value
4739 4769
 	 * @param bool $restate private
4770
+	 * @return string
4740 4771
 	 */
4741 4772
 	public static function state( $key = null, $value = null, $restate = false ) {
4742 4773
 		static $state = array();
@@ -4793,6 +4824,9 @@  discard block
 block discarded – undo
4793 4824
 		Jetpack::state( null, null, true );
4794 4825
 	}
4795 4826
 
4827
+	/**
4828
+	 * @param string $file
4829
+	 */
4796 4830
 	public static function check_privacy( $file ) {
4797 4831
 		static $is_site_publicly_accessible = null;
4798 4832
 
@@ -5120,7 +5154,7 @@  discard block
 block discarded – undo
5120 5154
 	/**
5121 5155
 	 * Pings the WordPress.com Mirror Site for the specified options.
5122 5156
 	 *
5123
-	 * @param string|array $option_names The option names to request from the WordPress.com Mirror Site
5157
+	 * @param string[] $option_names The option names to request from the WordPress.com Mirror Site
5124 5158
 	 *
5125 5159
 	 * @return array An associative array of the option values as stored in the WordPress.com Mirror Site
5126 5160
 	 */
@@ -5144,7 +5178,7 @@  discard block
 block discarded – undo
5144 5178
 	/**
5145 5179
 	 * Fetch the filtered array of options that we should compare to determine an identity crisis.
5146 5180
 	 *
5147
-	 * @return array An array of options to check.
5181
+	 * @return string[] An array of options to check.
5148 5182
 	 */
5149 5183
 	public static function identity_crisis_options_to_check() {
5150 5184
 		return array(
@@ -5516,8 +5550,8 @@  discard block
 block discarded – undo
5516 5550
 	 *  - Absolute URLs             `http://domain.com/feh.png`
5517 5551
 	 *  - Domain root relative URLs `/feh.png`
5518 5552
 	 *
5519
-	 * @param $css string: The raw CSS -- should be read in directly from the file.
5520
-	 * @param $css_file_url : The URL that the file can be accessed at, for calculating paths from.
5553
+	 * @param string $css string: The raw CSS -- should be read in directly from the file.
5554
+	 * @param string $css_file_url : The URL that the file can be accessed at, for calculating paths from.
5521 5555
 	 *
5522 5556
 	 * @return mixed|string
5523 5557
 	 */
@@ -5826,7 +5860,7 @@  discard block
 block discarded – undo
5826 5860
 	 *
5827 5861
 	 * @param string $option_name
5828 5862
 	 *
5829
-	 * @return bool
5863
+	 * @return false|null
5830 5864
 	 */
5831 5865
 	public static function jumpstart_has_updated_module_option( $option_name = '' ) {
5832 5866
 		// Bail if Jump Start has already been dismissed
@@ -5917,7 +5951,6 @@  discard block
 block discarded – undo
5917 5951
 	}
5918 5952
 
5919 5953
 	/**
5920
-	 * @param mixed $result Value for the user's option
5921 5954
 	 * @return mixed
5922 5955
 	 */
5923 5956
 	function get_user_option_meta_box_order_dashboard( $sorted ) {
Please login to merge, or discard this patch.
modules/wordads/php/admin.php 1 patch
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -141,6 +141,7 @@
 block discarded – undo
141 141
 
142 142
 	/**
143 143
 	 * @since 0.1
144
+	 * @param string $key
144 145
 	 */
145 146
 	function get_option( $key, $default = null ) {
146 147
 		// Options are limited to those specified in $this->valid_settings
Please login to merge, or discard this patch.
modules/wordads/wordads.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 	/**
48 48
 	 * Convenience function for grabbing options from params->options
49 49
 	 * @param  string $option the option to grab
50
-	 * @param  mixed  $default (optional)
50
+	 * @param  boolean  $default (optional)
51 51
 	 * @return option or $default if not set
52 52
 	 *
53 53
 	 * @since 0.1
@@ -304,7 +304,7 @@  discard block
 block discarded – undo
304 304
 	/**
305 305
 	 * Enforce Jetpack activated. Otherwise, load special no-jetpack admin.
306 306
 	 *
307
-	 * @return true if Jetpack is active and activated
307
+	 * @return boolean if Jetpack is active and activated
308 308
 	 *
309 309
 	 * @since 0.1
310 310
 	 */
@@ -325,7 +325,7 @@  discard block
 block discarded – undo
325 325
 
326 326
 	/**
327 327
 	 * Check the reasons to bail before we attempt to insert ads.
328
-	 * @return true if we should bail (don't insert ads)
328
+	 * @return boolean if we should bail (don't insert ads)
329 329
 	 *
330 330
 	 * @since 0.1
331 331
 	 */
Please login to merge, or discard this patch.