Rename getPullListFromRef to refPairsFromImageReference

This is a bit more specific as to what "ref" or "list" means,
and consistent with refPairsFromPossiblyUnqualifiedName

Should not change behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>

Closes: #1176
Approved by: rhatdan
This commit is contained in:
Miloslav Trmač
2018-07-27 01:20:58 +02:00
committed by Atomic Bot
parent d61bed2b2d
commit 6ddf81f07d

View File

@ -181,8 +181,8 @@ func refNamesFromImageReference(ctx context.Context, srcRef types.ImageReference
return pullNames, nil return pullNames, nil
} }
// getPullListFromRef returns a list of pullRefPair for a single ImageReference, depending on the used transport. // refPairsFromImageReference returns a list of pullRefPair for a single ImageReference, depending on the used transport.
func (ir *Runtime) getPullListFromRef(ctx context.Context, srcRef types.ImageReference, imgName string, sc *types.SystemContext) ([]*pullRefPair, error) { func (ir *Runtime) refPairsFromImageReference(ctx context.Context, srcRef types.ImageReference, imgName string, sc *types.SystemContext) ([]*pullRefPair, error) {
refNames, err := refNamesFromImageReference(ctx, srcRef, imgName, sc) refNames, err := refNamesFromImageReference(ctx, srcRef, imgName, sc)
if err != nil { if err != nil {
return nil, err return nil, err
@ -206,7 +206,7 @@ func (i *Image) pullImage(ctx context.Context, writer io.Writer, authfile, signa
return nil, errors.Wrap(err, "error getting default registries to try") return nil, errors.Wrap(err, "error getting default registries to try")
} }
} else { } else {
pullRefPairs, err = i.imageruntime.getPullListFromRef(ctx, srcRef, i.InputName, sc) pullRefPairs, err = i.imageruntime.refPairsFromImageReference(ctx, srcRef, i.InputName, sc)
if err != nil { if err != nil {
return nil, errors.Wrapf(err, "error getting pullRefPair info to pull image %q", i.InputName) return nil, errors.Wrapf(err, "error getting pullRefPair info to pull image %q", i.InputName)
} }