mirror of
https://github.com/tailscale/tailscale.git
synced 2025-04-22 08:51:41 +00:00
logtail: add PrivateID.IsZero method
This commit is contained in:
parent
9497921f52
commit
5d67365cc9
@ -55,6 +55,9 @@ func ParsePrivateID(s string) (PrivateID, error) {
|
|||||||
return p, nil
|
return p, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// IsZero reports whether id is the zero value.
|
||||||
|
func (id PrivateID) IsZero() bool { return id == PrivateID{} }
|
||||||
|
|
||||||
func (id *PrivateID) UnmarshalText(s []byte) error {
|
func (id *PrivateID) UnmarshalText(s []byte) error {
|
||||||
b, err := hex.DecodeString(string(s))
|
b, err := hex.DecodeString(string(s))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user