Completed
Push — add/nosara-tracks ( 3a9b0f...ccd674 )
by
unknown
89:29 queued 80:57
created
class.jetpack.php 1 patch
Doc Comments   +43 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1053,7 +1053,7 @@  discard block
 block discarded – undo
1053 1053
 	}
1054 1054
 	/**
1055 1055
 	 * Does the network allow admins to add new users.
1056
-	 * @return boolian
1056
+	 * @return boolean
1057 1057
 	 */
1058 1058
 	static function network_add_new_users( $option = null ) {
1059 1059
 		return (bool) get_site_option( 'add_new_users' );
@@ -1101,7 +1101,7 @@  discard block
 block discarded – undo
1101 1101
 	 * database which could be set to anything as opposed to what this function returns.
1102 1102
 	 * @param  bool  $option
1103 1103
 	 *
1104
-	 * @return boolean
1104
+	 * @return string
1105 1105
 	 */
1106 1106
 	public function is_main_network_option( $option ) {
1107 1107
 		// return '1' or ''
@@ -1112,7 +1112,7 @@  discard block
 block discarded – undo
1112 1112
 	 * Return true if we are with multi-site or multi-network false if we are dealing with single site.
1113 1113
 	 *
1114 1114
 	 * @param  string  $option
1115
-	 * @return boolean
1115
+	 * @return string
1116 1116
 	 */
1117 1117
 	public function is_multisite( $option ) {
1118 1118
 		return (string) (bool) is_multisite();
@@ -1210,7 +1210,7 @@  discard block
 block discarded – undo
1210 1210
 
1211 1211
 	/**
1212 1212
 	 * Returns true if the site has file write access false otherwise.
1213
-	 * @return string ( '1' | '0' )
1213
+	 * @return integer ( '1' | '0' )
1214 1214
 	 **/
1215 1215
 	public static function file_system_write_access() {
1216 1216
 		if ( ! function_exists( 'get_filesystem_method' ) ) {
@@ -1972,7 +1972,7 @@  discard block
 block discarded – undo
1972 1972
 	 * Returns the requested option.  Looks in jetpack_options or jetpack_$name as appropriate.
1973 1973
  	 *
1974 1974
 	 * @param string $name    Option name
1975
-	 * @param mixed  $default (optional)
1975
+	 * @param boolean  $default (optional)
1976 1976
 	 */
1977 1977
 	public static function get_option( $name, $default = false ) {
1978 1978
 		return Jetpack_Options::get_option( $name, $default );
@@ -1982,6 +1982,7 @@  discard block
 block discarded – undo
1982 1982
 	* Stores two secrets and a timestamp so WordPress.com can make a request back and verify an action
1983 1983
 	* Does some extra verification so urls (such as those to public-api, register, etc) can't just be crafted
1984 1984
 	* $name must be a registered option name.
1985
+	* @param string $name
1985 1986
 	*/
1986 1987
 	public static function create_nonce( $name ) {
1987 1988
 		$secret = wp_generate_password( 32, false ) . ':' . wp_generate_password( 32, false ) . ':' . ( time() + 600 );
@@ -2039,6 +2040,7 @@  discard block
 block discarded – undo
2039 2040
 	 * @param int $user_id
2040 2041
 	 * @param string $token
2041 2042
 	 * return bool
2043
+	 * @param boolean $is_master_user
2042 2044
 	 */
2043 2045
 	public static function update_user_token( $user_id, $token, $is_master_user ) {
2044 2046
 		// not designed for concurrent updates
@@ -2433,6 +2435,7 @@  discard block
 block discarded – undo
2433 2435
 
2434 2436
 	/**
2435 2437
 	 * Like core's get_file_data implementation, but caches the result.
2438
+	 * @param string $file
2436 2439
 	 */
2437 2440
 	public static function get_file_data( $file, $headers ) {
2438 2441
 		//Get just the filename from $file (i.e. exclude full path) so that a consistent hash is generated
@@ -2456,6 +2459,9 @@  discard block
 block discarded – undo
2456 2459
 		return $data;
2457 2460
 	}
2458 2461
 
2462
+	/**
2463
+	 * @param string $untranslated_tag
2464
+	 */
2459 2465
 	public static function translate_module_tag( $untranslated_tag ) {
2460 2466
 		// Tags are aggregated by tools/build-module-headings-translations.php
2461 2467
 		// and output in modules/module-headings.php
@@ -2748,6 +2754,9 @@  discard block
 block discarded – undo
2748 2754
 		$this->sync->sync_all_module_options( $module );
2749 2755
 	}
2750 2756
 
2757
+	/**
2758
+	 * @return string
2759
+	 */
2751 2760
 	public static function deactivate_module( $module ) {
2752 2761
 		/**
2753 2762
 		 * Fires when a module is deactivated.
@@ -2786,6 +2795,9 @@  discard block
 block discarded – undo
2786 2795
 		return Jetpack_Options::update_option( 'active_modules', array_unique( $new ) );
2787 2796
 	}
2788 2797
 
2798
+	/**
2799
+	 * @param string $module
2800
+	 */
2789 2801
 	public static function enable_module_configurable( $module ) {
2790 2802
 		$module = Jetpack::get_module_slug( $module );
2791 2803
 		add_filter( 'jetpack_module_configurable_' . $module, '__return_true' );
@@ -2796,21 +2808,33 @@  discard block
 block discarded – undo
2796 2808
 		return Jetpack::admin_url( array( 'page' => 'jetpack', 'configure' => $module ) );
2797 2809
 	}
2798 2810
 
2811
+	/**
2812
+	 * @param string $module
2813
+	 */
2799 2814
 	public static function module_configuration_load( $module, $method ) {
2800 2815
 		$module = Jetpack::get_module_slug( $module );
2801 2816
 		add_action( 'jetpack_module_configuration_load_' . $module, $method );
2802 2817
 	}
2803 2818
 
2819
+	/**
2820
+	 * @param string $module
2821
+	 */
2804 2822
 	public static function module_configuration_head( $module, $method ) {
2805 2823
 		$module = Jetpack::get_module_slug( $module );
2806 2824
 		add_action( 'jetpack_module_configuration_head_' . $module, $method );
2807 2825
 	}
2808 2826
 
2827
+	/**
2828
+	 * @param string $module
2829
+	 */
2809 2830
 	public static function module_configuration_screen( $module, $method ) {
2810 2831
 		$module = Jetpack::get_module_slug( $module );
2811 2832
 		add_action( 'jetpack_module_configuration_screen_' . $module, $method );
2812 2833
 	}
2813 2834
 
2835
+	/**
2836
+	 * @param string $module
2837
+	 */
2814 2838
 	public static function module_configuration_activation_screen( $module, $method ) {
2815 2839
 		$module = Jetpack::get_module_slug( $module );
2816 2840
 		add_action( 'display_activate_module_setting_' . $module, $method );
@@ -2818,6 +2842,9 @@  discard block
 block discarded – undo
2818 2842
 
2819 2843
 /* Installation */
2820 2844
 
2845
+	/**
2846
+	 * @param string $message
2847
+	 */
2821 2848
 	public static function bail_on_activation( $message, $deactivate = true ) {
2822 2849
 ?>
2823 2850
 <!doctype html>
@@ -3431,7 +3458,7 @@  discard block
 block discarded – undo
3431 3458
 	 * Add help to the Jetpack page
3432 3459
 	 *
3433 3460
 	 * @since Jetpack (1.2.3)
3434
-	 * @return false if not the Jetpack page
3461
+	 * @return false|null if not the Jetpack page
3435 3462
 	 */
3436 3463
 	function admin_help() {
3437 3464
 		$current_screen = get_current_screen();
@@ -4721,6 +4748,7 @@  discard block
 block discarded – undo
4721 4748
 	/**
4722 4749
 	 * Returns the requested Jetpack API URL
4723 4750
 	 *
4751
+	 * @param string $relative_url
4724 4752
 	 * @return string
4725 4753
 	 */
4726 4754
 	public static function api_url( $relative_url ) {
@@ -5146,6 +5174,10 @@  discard block
 block discarded – undo
5146 5174
 		return new WP_User( $token_details['user_id'] );
5147 5175
 	}
5148 5176
 
5177
+	/**
5178
+	 * @param integer $timestamp
5179
+	 * @param string $nonce
5180
+	 */
5149 5181
 	function add_nonce( $timestamp, $nonce ) {
5150 5182
 		global $wpdb;
5151 5183
 		static $nonces_used_this_request = array();
@@ -5351,6 +5383,9 @@  discard block
 block discarded – undo
5351 5383
 		Jetpack::state( null, null, true );
5352 5384
 	}
5353 5385
 
5386
+	/**
5387
+	 * @param string $file
5388
+	 */
5354 5389
 	public static function check_privacy( $file ) {
5355 5390
 		static $is_site_publicly_accessible = null;
5356 5391
 
@@ -6332,8 +6367,8 @@  discard block
 block discarded – undo
6332 6367
 	 *  - Absolute URLs             `http://domain.com/feh.png`
6333 6368
 	 *  - Domain root relative URLs `/feh.png`
6334 6369
 	 *
6335
-	 * @param $css string: The raw CSS -- should be read in directly from the file.
6336
-	 * @param $css_file_url : The URL that the file can be accessed at, for calculating paths from.
6370
+	 * @param string $css string: The raw CSS -- should be read in directly from the file.
6371
+	 * @param string $css_file_url : The URL that the file can be accessed at, for calculating paths from.
6337 6372
 	 *
6338 6373
 	 * @return mixed|string
6339 6374
 	 */
@@ -6731,7 +6766,6 @@  discard block
 block discarded – undo
6731 6766
 	}
6732 6767
 
6733 6768
 	/**
6734
-	 * @param mixed $result Value for the user's option
6735 6769
 	 * @return mixed
6736 6770
 	 */
6737 6771
 	function get_user_option_meta_box_order_dashboard( $sorted ) {
Please login to merge, or discard this patch.