Skip to content

Commit

Permalink
clarify comment
Browse files Browse the repository at this point in the history
  • Loading branch information
mfridman committed Dec 5, 2024
1 parent e27a190 commit 2f9dbb7
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,9 @@ func newGoRegistryConfig(
if err != nil {
return nil, fmt.Errorf("failed to parse base plugin: %w", err)
}
// If plugin dependencies are specified, then the base plugin must also exist in that list.
// Validate the base plugin is included as one of the plugin dependencies when both are
// specified. This ensures there's exactly one base type and it has a known dependency to
// generate imports correctly and build a correct Go mod file.
if len(pluginDependencies) > 0 {
ok := slices.ContainsFunc(pluginDependencies, func(ref bufremotepluginref.PluginReference) bool {
return ref.IdentityString() == basePlugin.IdentityString()
Expand Down

0 comments on commit 2f9dbb7

Please sign in to comment.