Skip to content

Plugin Updater Check does not detect PUC library usage #1167

@ernilambar

Description

@ernilambar

The look_for_plugin_updaters() function in Plugin_Updater_Check does not detect plugins that use the YahnisElsts Plugin Update Checker library.

Example code that is currently not detected:

$update_checker = YahnisElsts\PluginUpdateChecker\v5\PucFactory::buildUpdateChecker(
	'https://example.com/plugin-info.json',
	__FILE__,
	'my-plugin-slug'
);

Current code:

$look_for_regex = array(
	'#\'plugin-update-checker\'#',
	'#WP_GitHub_Updater#',
	'#WPGitHubUpdater#',
	'#class [A-Z_]+_Plugin_Updater#i',
	'#updater\.\w+\.\w{2,5}#i',
	'#site_transient_update_plugins#',
);

This pattern uses the YahnisElsts\PluginUpdateChecker\v5\PucFactory::buildUpdateChecker() static method to add custom update functionality, which is not permitted.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions