mirror of https://github.com/perkeep/perkeep.git
blobref: Equal on nils
Change-Id: Idb6a2ba14a4e92b2b619e5cce87174bf80f2090f
This commit is contained in:
parent
476329cfb3
commit
f7ab48b0d8
|
@ -106,6 +106,12 @@ func (b *BlobRef) DomID() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *BlobRef) Equal(other *BlobRef) bool {
|
func (o *BlobRef) Equal(other *BlobRef) bool {
|
||||||
|
if (o == nil) != (other == nil) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
if o == nil {
|
||||||
|
return true
|
||||||
|
}
|
||||||
return o.hashName == other.hashName && o.digest == other.digest
|
return o.hashName == other.hashName && o.digest == other.digest
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue