AnsPress_Prod_Updater::plugins_api_filter( mixed $_data, string $_action = '', object $_args = null )
Description #
Updates information on the “View version x.x details” page with custom data.
Parameters #
- $_datamixed (Required)
- $_actionstring (Optional) Default value: ''
- $_argsobject (Optional) Default value: null
Source #
File: admin/updater.php
public function plugins_api_filter( $_data, $_action = '', $_args = null ) {
if ( $_action != 'plugin_information' ) {
return $_data;
}
if ( ! isset( $_args->slug ) || ( $_args->slug != $this->slug ) ) {
return $_data;
}
$to_send = array(
'slug' => $this->slug,
'is_ssl' => is_ssl(),
'fields' => array(
'banners' => false, // These will be supported soon hopefully
'reviews' => false,
),
);
$api_response = $this->api_request( 'plugin_information', $to_send );
if ( false !== $api_response ) {
$_data = $api_response;
}
return $_data;
}
Expand full source code Collapse full source code View on GitHub: admin/updater.php:262
Add your comment