mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
d910781c66
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
12 lines
243 B
Go
12 lines
243 B
Go
package reference
|
|
|
|
// IsNameOnly returns true if reference only contains a repo name.
|
|
func IsNameOnly(ref Named) bool {
|
|
if _, ok := ref.(NamedTagged); ok {
|
|
return false
|
|
}
|
|
if _, ok := ref.(Canonical); ok {
|
|
return false
|
|
}
|
|
return true
|
|
}
|