Skip to content

Commit b892b03

Browse files
Copilotswissspidy
andcommitted
Fix type inconsistency in is_active method
Co-authored-by: swissspidy <[email protected]>
1 parent b0c8d9d commit b892b03

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Plugin_Command.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1392,7 +1392,7 @@ public function is_active( $args, $assoc_args ) {
13921392
}
13931393

13941394
// Try to find a matching plugin file in active_plugins
1395-
$found_in_active = false;
1395+
$found_in_active = '';
13961396
foreach ( $active_plugin_files as $plugin_file ) {
13971397
// Ensure plugin_file is a string
13981398
if ( ! is_string( $plugin_file ) ) {
@@ -1408,7 +1408,7 @@ public function is_active( $args, $assoc_args ) {
14081408
}
14091409
}
14101410

1411-
if ( is_string( $found_in_active ) && $found_in_active ) {
1411+
if ( $found_in_active ) {
14121412
// Plugin is in active_plugins but file doesn't exist
14131413
// Use validate_plugin to confirm the file is missing
14141414
$validation = validate_plugin( $found_in_active );

0 commit comments

Comments
 (0)