Skip to content

Commit

Permalink
coding standards fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
remyperona committed Feb 22, 2024
1 parent 4502844 commit 6a64753
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 4 deletions.
3 changes: 3 additions & 0 deletions classes/Avif/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
use Imagify\Dependencies\League\Container\ServiceProvider\AbstractServiceProvider;
use Imagify\Avif\RewriteRules\Display as RewriteRules;

/**
* Service provider for AVIF rewrite rules
*/
class ServiceProvider extends AbstractServiceProvider {
/**
* Services provided by this provider
Expand Down
3 changes: 3 additions & 0 deletions classes/CDN/CDN.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

use Imagify\EventManagement\SubscriberInterface;

/**
* CDN subscriber
*/
class CDN implements SubscriberInterface {
/**
* Array of events this subscriber listens to
Expand Down
3 changes: 3 additions & 0 deletions classes/CDN/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

use Imagify\Dependencies\League\Container\ServiceProvider\AbstractServiceProvider;

/**
* Service provider for CDN compatibility
*/
class ServiceProvider extends AbstractServiceProvider {
/**
* Services provided by this provider
Expand Down
6 changes: 4 additions & 2 deletions classes/Picture/Display.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ class Display implements SubscriberInterface {

/**
* Constructor.
*
* @param Imagify_Filesystem $filesystem Filesystem instance.
*/
public function __construct( Imagify_Filesystem $filesystem ) {
$this->filesystem = $filesystem;
Expand Down Expand Up @@ -65,7 +67,7 @@ public function start_content_process() {
return;
}

$allow = apply_filters_deprecated( 'imagify_allow_picture_tags_for_webp', [true ], '2.2', 'imagify_allow_picture_tags_for_nextgen' );
$allow = apply_filters_deprecated( 'imagify_allow_picture_tags_for_webp', [ true ], '2.2', 'imagify_allow_picture_tags_for_nextgen' );

/**
* Prevent the replacement of <img> tags into <picture> tags.
Expand Down Expand Up @@ -246,7 +248,7 @@ protected function build_picture_tag( $image ) {
protected function build_source_tag( $image ) {
$source = '';

foreach ( [ 'avif', 'webp' ] as $image_type ) {
foreach ( [ 'avif', 'webp' ] as $image_type ) {
$attributes = $this->build_source_attributes( $image, $image_type );

if ( empty( $attributes ) ) {
Expand Down
3 changes: 3 additions & 0 deletions classes/Picture/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

use Imagify\Dependencies\League\Container\ServiceProvider\AbstractServiceProvider;

/**
* Service provider for Picture display
*/
class ServiceProvider extends AbstractServiceProvider {
/**
* Services provided by this provider
Expand Down
4 changes: 2 additions & 2 deletions classes/Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ private function is_loaded(): bool {
/**
* Plugin init.
*
* @param array Array of service providers.
* @param array $providers Array of service providers.
*
* @since 1.9
*/
Expand Down Expand Up @@ -243,7 +243,7 @@ public function maybe_activate() {
/**
* Load list of event subscribers from service provider.
*
* @param ServiceProviderInterface $service_provider_instance Instance of service provider.
* @param ServiceProviderInterface $service_provider Instance of service provider.
*
* @return void
*/
Expand Down
3 changes: 3 additions & 0 deletions classes/Webp/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
use Imagify\Dependencies\League\Container\ServiceProvider\AbstractServiceProvider;
use Imagify\Webp\RewriteRules\Display as RewriteRules;

/**
* Service provider for WebP rewrite rules
*/
class ServiceProvider extends AbstractServiceProvider {
/**
* Services provided by this provider
Expand Down

0 comments on commit 6a64753

Please sign in to comment.