Change TargetIndex to only search by uuid
Note this reverses a change made in https://github.com/hashicorp/vagrant-ruby/pull/180 to attempt to address issues losing track of machines. Further testing is in order to verify we haven't re-broken that, but after discussion we agreed this is the correct behavior for the index.
This commit is contained in:
parent
06350a7afc
commit
52ed086644
@ -47,15 +47,7 @@ func (t *TargetIndex) Get(uuid string) (entry core.Target, err error) {
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
// Search name if not found by uuid
|
||||
result, err = t.client.FindTarget(t.ctx, &vagrant_server.FindTargetRequest{
|
||||
Target: &vagrant_server.Target{
|
||||
Name: uuid,
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
return t.loadTarget(&vagrant_plugin_sdk.Ref_Target{
|
||||
ResourceId: result.Target.ResourceId,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user