Premium plugin updates detected but only when Active on sites, missing update when Inactivate

Hello,

I’m curious why MainWP struggles so much with some premium plugins. While the code snippet below works to some degree it seems to only apply if the plugin is Active on the child site. In other words, if I had a plugin installed on 10 sites but only active on 6, MainWP detects only 6 child sites to update the premium plugin when a new version is released.

How can I ensure MainWP detects premium plugins even when Inactive on a child site?

FWIW, here’s my code snippet for premium plugins across my child sites:

///// enable better update detection for premium plugins
add_filter('mainwp_detect_premium_plugins_update', 'd19_mainwp_detect_premium_plugins_update', 10);
function d19_mainwp_detect_premium_plugins_update($premiums)
{
    $premiums[] = 'bricksextras/bricksextras.php';
	$premiums[] = 'bricksextras/includes/Plugin.php';
	$premiums[] = 'fluentformspro/fluentformspro.php';
    $premiums[] = 'flying-press/flying-press.php';
    $premiums[] = 'oxygen/functions.php';
	$premiums[] = 'wp-rocket/wp-rocket.php';
	$premiums[] = 'wp-seopress-pro/seopress-pro.php';
	$premiums[] = 'wp-social-ninja-pro/wp-social-ninja-pro.php';
    return $premiums;
}
///// enable better update detection for premium themes
add_filter('mainwp_detect_premium_themes_update', 'd19_mainwp_detect_premium_plugins_update', 10);
function d19_mainwp_detect_premium_themes_update($premiums)
{
    $premiums[] = 'bricks/functions.php';
    return $premiums;
}
1 Like

Hey @d19dotca

Premium plugins can have their own peculiar way of checking if there’s an update available.

Is the issue occurring only with specific inactive premium plugins, or with all inactive premium plugins?

When there’s an update available for a specific active Premium plugin, you explained that MainWP does not show an available update for a different child site where the plugin is inactive. But when you go to the WP Admin of that other site with an inactive premium plugin, does it show an available update there?

1 Like

It’s all premium plugins as best I can tell, I can’t think of any that actually show up for sites where they’re Inactive.

I believe in my experience the update shows on the child site if I go to it’s WP Admin directly, just not seen in MainWP for some reason unless it’s actually an Active plugin. I’ll try to be more aware of that when the next update comes though just in case.

2 Likes

Most premium plugins (and themes) don’t check for updates if their code isn’t executed.Because they have their own update mechanisms, WordPress (or MainWP) has no way to check and install these updates. MainWP should be able to show all the updates that are visible in the Updates screen of WordPress.

2 Likes

Thanks for the update.

Let us know if you see that an inactive premium theme is showing up available update in WordPress Admin but not in MainWP so that we can investigate further.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.