Skip to content

Commit 18a53e8

Browse files
committed
Find a plugin using the correct name
`name` is the name of the configuration section, not the name of the provider. So use `pname`, like the other parts of the code.
1 parent 3e9a20d commit 18a53e8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

registry.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ func NewProvider(pname, name string) (HostProvider, error) {
9292
if !ok {
9393
// Try finding a plugin by this name, if we have the provider plugin loaded
9494
if c, ok := availableProviders["plugin"]; ok {
95-
if _, err := exec.LookPath(fmt.Sprintf("herd-provider-%s", name)); err == nil {
95+
if _, err := exec.LookPath(fmt.Sprintf("herd-provider-%s", pname)); err == nil {
9696
return c(name), nil
9797
}
9898
}

0 commit comments

Comments
 (0)