Disable markup in the get_plugin_data() return in order to fix the issue with incorrect early initialization of wptexturize() (652)

This commit is contained in:
Daniel Dudzic 2024-03-13 12:01:36 +01:00
parent f448fabe3c
commit 89e56b9e72
No known key found for this signature in database
GPG key ID: 31B40D33E3465483
2 changed files with 3 additions and 3 deletions

View file

@ -65,7 +65,7 @@ class FilePathPluginFactory implements FilePathPluginFactoryInterface {
require_once ABSPATH . 'wp-admin/includes/plugin.php';
}
$plugin_data = get_plugin_data( $filePath );
$plugin_data = get_plugin_data( $filePath, false );
if ( empty( $plugin_data ) ) {
throw new UnexpectedValueException(
sprintf(
@ -98,7 +98,7 @@ class FilePathPluginFactory implements FilePathPluginFactoryInterface {
$this->create_version( $plugin_data['Version'] ),
$base_dir,
$base_name,
$plugin_data['Title'],
'blah',
$plugin_data['Description'],
$text_domain,
$this->create_version( $plugin_data['RequiresPHP'] ),

View file

@ -97,7 +97,7 @@ define( 'PAYPAL_INTEGRATION_DATE', '2024-03-12' );
*/
require_once ABSPATH . 'wp-admin/includes/plugin.php';
}
$plugin_data = get_plugin_data( __DIR__ . '/woocommerce-paypal-payments.php' );
$plugin_data = get_plugin_data( __DIR__ . '/woocommerce-paypal-payments.php', false );
$plugin_version = $plugin_data['Version'] ?? null;
$installed_plugin_version = get_option( 'woocommerce-ppcp-version' );
if ( $installed_plugin_version !== $plugin_version ) {