This is an automated email from the ASF dual-hosted git repository. elharo pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/maven-enforcer.git
The following commit(s) were added to refs/heads/master by this push: new c365b46 return not needed (#352) c365b46 is described below commit c365b464af08ef0c997880a635edcbca6d263fe9 Author: Elliotte Rusty Harold <elh...@users.noreply.github.com> AuthorDate: Fri Feb 21 21:02:19 2025 +0000 return not needed (#352) * return not needed --- .../org/apache/maven/enforcer/rules/RequirePluginVersions.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/enforcer-rules/src/main/java/org/apache/maven/enforcer/rules/RequirePluginVersions.java b/enforcer-rules/src/main/java/org/apache/maven/enforcer/rules/RequirePluginVersions.java index 20218d6..8c4e209 100644 --- a/enforcer-rules/src/main/java/org/apache/maven/enforcer/rules/RequirePluginVersions.java +++ b/enforcer-rules/src/main/java/org/apache/maven/enforcer/rules/RequirePluginVersions.java @@ -63,7 +63,6 @@ import org.apache.maven.plugin.InvalidPluginException; import org.apache.maven.plugin.PluginManager; import org.apache.maven.plugin.PluginManagerException; import org.apache.maven.plugin.PluginNotFoundException; -import org.apache.maven.plugin.descriptor.PluginDescriptor; import org.apache.maven.plugin.version.PluginVersionNotFoundException; import org.apache.maven.plugin.version.PluginVersionResolutionException; import org.apache.maven.project.MavenProject; @@ -782,12 +781,11 @@ public final class RequirePluginVersions extends AbstractStandardEnforcerRule { * @throws LifecycleExecutionException the lifecycle execution exception * @throws PluginNotFoundException the plugin not found exception */ - private PluginDescriptor verifyPlugin( + private void verifyPlugin( Plugin plugin, MavenProject project, Settings settings, ArtifactRepository localRepository) throws LifecycleExecutionException, PluginNotFoundException { - PluginDescriptor pluginDescriptor; try { - pluginDescriptor = pluginManager.verifyPlugin(plugin, project, settings, localRepository); + pluginManager.verifyPlugin(plugin, project, settings, localRepository); } catch (PluginManagerException e) { throw new LifecycleExecutionException( "Internal error in the plugin manager getting plugin '" + plugin.getKey() + "': " + e.getMessage(), @@ -800,7 +798,6 @@ public final class RequirePluginVersions extends AbstractStandardEnforcerRule { | ArtifactNotFoundException e) { throw new LifecycleExecutionException(e.getMessage(), e); } - return pluginDescriptor; } /**