Scope down rescue on BoxCollection.find

After https://github.com/hashicorp/vagrant-plugin-sdk/pull/175 is merged
it will properly return a NotFound so we can rescue that specifically
and let any unexpected errors propagate.
This commit is contained in:
Paul Hinze 2022-06-24 16:30:51 -05:00
parent 708b688b3f
commit 47962dff37
No known key found for this signature in database
GPG Key ID: B69DEDF2D55501C0

View File

@ -52,7 +52,7 @@ module VagrantPlugins
res = client.find(SDK::BoxCollection::FindRequest.new(
name: name, version: version, providers: Array(providers)
))
rescue
rescue GRPC::NotFound
logger.debug("box not found!")
return nil
end