Skip to content

Commit

Permalink
Use the resolver from the image
Browse files Browse the repository at this point in the history
Co-authored-by: Joshua Humphries <[email protected]>
  • Loading branch information
emcfarlane and jhump authored Jan 14, 2025
1 parent 665110a commit aca44b7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions private/bufpkg/bufcheck/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,7 @@ func imageToProtoFileDescriptors(image bufimage.Image) ([]*descriptorv1.FileDesc
}
resolver := protoencoding.CombineResolvers(
goFeaturesResolver,
protoencoding.NewLazyResolver(slicesext.Map(descriptors, func(fileDescriptor *descriptorv1.FileDescriptor) *descriptorpb.FileDescriptorProto {
return fileDescriptor.FileDescriptorProto
})...),
image.Resolver(),
)
for _, descriptor := range reparseDescriptors {
// We clone the FileDescriptorProto to avoid modifying the original.
Expand Down

0 comments on commit aca44b7

Please sign in to comment.