diff --git a/endpoint/jobid.go b/endpoint/jobid.go index 63248c0..372b6f9 100644 --- a/endpoint/jobid.go +++ b/endpoint/jobid.go @@ -9,8 +9,8 @@ import ( "github.com/zrepl/zrepl/zfs" ) -// An instance of this type returned by MakeJobID guarantees -// that that instance's JobID.String() can be used in a ZFS dataset name and hold tag. +// JobID instances returned by MakeJobID() guarantee their JobID.String() +// can be used in ZFS dataset names and hold tags. type JobID struct { jid string } @@ -21,7 +21,7 @@ func MakeJobID(s string) (JobID, error) { } if err := zfs.ComponentNamecheck(s); err != nil { - return JobID{}, errors.Wrap(err, "muse be usable as a dataset path component") + return JobID{}, errors.Wrap(err, "must be usable as a dataset path component") } if _, err := stepBookmarkNameImpl("pool/ds", 0xface601d, s); err != nil { @@ -34,7 +34,7 @@ func MakeJobID(s string) (JobID, error) { } if _, err := lastReceivedHoldImpl(s); err != nil { - return JobID{}, errors.Wrap(err, "must be usabel as a last-recieved-hold tag") + return JobID{}, errors.Wrap(err, "must be usable as a last-received-hold tag") } // FIXME replication cursor bookmark name @@ -57,7 +57,7 @@ func MustMakeJobID(s string) JobID { func (j JobID) expectInitialized() { if j.jid == "" { - panic("use of unitialized JobID") + panic("use of uninitialized JobID") } }