Open fiskhandlarn opened 2 years ago
also: wordpress-seo-premium/src/addon-installer.php
already have is_yoast_seo_up_to_date()
which checks WPSEO_VERSION
and could therefore be used instead of checking against $this->yoast_seo_version
(derived from the wordpress-seo/wp-seo.php
only if it's in the plugins
folder).
+1 for this.
The other approach here could be that the Wordpress SEO plugin could just have a filter to provide the version to other plugins.
e.g. in the non premium version:
add_filter('wp_seo_current_version', function($version) {
return '1.1.1';
}, 10, 1);
Then in the premium plugin the version would be checked with:
$value = apply_filters( 'wp_seo_current_version', '0');
If the plugin is installed and active, the version would be returned as '1.1.1'. If it was not installed the $value would be '0'.
This would mean a version would be returned regardless of whether it's a plugin or mu-plugin.
Only caveat here is that another plugin could fake the version by returning a value from this filter (but why would they?)
+1
bump
Is your feature request related to a problem? Please describe.
when we run
yoast/wordpress-seo
andyoast/wordpress-seo-premium
as mu-plugins (courtesy ofroots/bedrock-autoloader
) we still get the nag to activate the base plugin:Describe the solution you'd like
this is a patch for
wordpress-seo-premium/src/addon-installer.php
i have tried locally, please consider adding it toyoast/wordpress-seo-premium
:Why do you think this feature is something we should consider for the Yoast SEO plugins?
some people like to use mu-plugins to streamline all the requirements without having to manually activate and keep databases in sync.