Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function auv_plugin_api( $false, $action, $arg ){
- if (isset($arg->slug) && $arg->slug === plugin_basename( __FILE__ ) ) {
- $request = wp_remote_get( 'http://websupporter.net/current-version.php' );
- if (!is_wp_error( $request ) || wp_remote_retrieve_response_code( $request ) === 200 ) {
- return unserialize( $request['body'] );
- }
- return false;
- }
- }
- add_filter( 'plugins_api', 'auv_plugin_api', 10, 3 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement