Completed
Push — master ( 241ea6...f0ce99 )
by Stephanie
03:24
created
classes/models/FrmEDD_SL_Plugin_Updater.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
 	 * @uses api_request()
71 71
 	 *
72 72
 	 * @param array   $_transient_data Update array build by WordPress.
73
-	 * @return array Modified update array with custom plugin data.
73
+	 * @return stdClass Modified update array with custom plugin data.
74 74
 	 */
75 75
 	public function check_update( $_transient_data ) {
76 76
 
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 		$this->slug     = basename( $_plugin_file, '.php' );
41 41
 		$this->version  = $_api_data['version'];
42 42
 
43
-		$frm_edd_plugin_data[ $this->slug ] = $this->api_data;
43
+		$frm_edd_plugin_data[$this->slug] = $this->api_data;
44 44
 
45 45
 		// Set up hooks.
46 46
 		$this->init();
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
 			$_transient_data = new stdClass;
81 81
 		}
82 82
 
83
-		if ( empty( $_transient_data->response ) || empty( $_transient_data->response[ $this->name ] ) ) {
83
+		if ( empty( $_transient_data->response ) || empty( $_transient_data->response[$this->name] ) ) {
84 84
 
85 85
 			$version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug ) );
86 86
 
@@ -92,12 +92,12 @@  discard block
 block discarded – undo
92 92
 						$version_info->plugin = $this->name;
93 93
 					}
94 94
 
95
-					$_transient_data->response[ $this->name ] = $version_info;
95
+					$_transient_data->response[$this->name] = $version_info;
96 96
 
97 97
 				}
98 98
 
99 99
 				$_transient_data->last_checked = time();
100
-				$_transient_data->checked[ $this->name ] = $this->version;
100
+				$_transient_data->checked[$this->name] = $this->version;
101 101
 
102 102
 			}
103 103
 		}
@@ -242,7 +242,7 @@  discard block
 block discarded – undo
242 242
 			wp_die( __( 'You do not have permission to install plugin updates', 'formidable' ), __( 'Error', 'formidable' ), array( 'response' => 403 ) );
243 243
 		}
244 244
 
245
-		$data         = $frm_edd_plugin_data[ $_REQUEST['slug'] ];
245
+		$data         = $frm_edd_plugin_data[$_REQUEST['slug']];
246 246
 		$cache_key    = md5( 'edd_plugin_' . sanitize_key( $_REQUEST['plugin'] ) . '_version_info' );
247 247
 		$version_info = get_transient( $cache_key );
248 248
 
Please login to merge, or discard this patch.