Ipstenu / varnish-http-purge

Proxy Cache Purge
Apache License 2.0
46 stars 47 forks source link

Fix PHPCS (WordPress Code Style) notices and warnings. #17

Closed LehaMotovilov closed 8 years ago

LehaMotovilov commented 8 years ago

Fix some notices and warnings by Code Style. https://make.wordpress.org/core/handbook/best-practices/coding-standards/php/

Ipstenu commented 8 years ago

Facebook pinging is inappropriate. As the owner of a project, I get alerts when you submit pull requests,

However I will be declining as the plugin's lack of code 'standards' per core have caused you to rename functions, and that will cause issues with people who use the plugin today. Since the changes appear to be only stylistic, I appreciate them, but I cannot blanket accept things that rename functions.

LehaMotovilov commented 8 years ago

Maybe we can try to make fallbacks like this? What do you think?

public function purgePost( $post_id ) {
    _deprecated_function( 'purgePost', '3.8.1' );

    $this->purge_post( $post_id );
}
Ipstenu commented 8 years ago

Could, but I value internal consistency above making cosmetic changes just for the sake of making cosmetic changes.

Also please understand, the WP core style guidelines are for core WordPress only. They are not now, nor have they ever been, applicable to any plugins with the exception of Feature Plugins. Which this is not.